Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
Discussion GroupsGeneralPHPASPPerlColdFusionFlashHTML, CSS, ScriptsBrowsers

Webmaster Forum / HTML, CSS, Scripts / CSS / May 2007



Tip: Looking for answers? Try searching our database.

how to display an wide table IE error

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Harris Kosmidhs - 30 May 2007 11:58 GMT
Hello. Please check http://www.mavridis-hotel.gr/prices.php

In FF the table -which is wide- goes way of the container it's in. And
it displays nice.

In IE7 since it doesn't fit it renders to the bottom of the page. How
can I achive the same effect in IE?

Thanks
Bergamot - 30 May 2007 13:26 GMT
> http://www.mavridis-hotel.gr/prices.php
>
> In FF the table -which is wide- goes way of the container it's in.
> In IE7 since it doesn't fit it renders to the bottom of the page.

IE7 is not the only browser that has the table at the bottom. I think
this is the first time I've seen Seamonkey and Firefox render differently.

> How can I achive the same effect in IE?

Your DOCTYPE triggers quirks mode. It is unlikely you'll get consistent
results across browsers unless you use standards mode.
http://www.hut.fi/u/hsivonen/doctype.html

Signature

Berg

Harris Kosmidhs - 30 May 2007 15:12 GMT
>> How can I achive the same effect in IE?
>
> Your DOCTYPE triggers quirks mode. It is unlikely you'll get consistent
> results across browsers unless you use standards mode.
> http://www.hut.fi/u/hsivonen/doctype.html

Ok got it. I use

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

which renders correctly after some minor changes and the table displays
well.

Now I git 2 problems.

1)It's more generic. Since I 'm writting in php using befor DOCTYPE
<?xml version="1.0" encoding="UTF-8"?> give a PHP error. Any hint?
(except allowing only the use of <?php ?>

2) Now the div#middle which has height 100% isn`t shown as before :-(
That means it isn't expanding until the bottom of the screen. Can I
overcome this?

Thanks a lot.
John Hosking - 30 May 2007 15:00 GMT
>> Your DOCTYPE triggers quirks mode. It is unlikely you'll get consistent
>> results across browsers unless you use standards mode.
>> http://www.hut.fi/u/hsivonen/doctype.html
>
> Ok got it.

Don't be so sure.

>    I use
>
> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
> "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

The URL you gave, http://www.mavridis-hotel.gr/prices.php, still uses
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">.

> which renders correctly after some minor changes and the table displays
> well.

Possibly, depending on the browser you're using and whatever page you're
actually looking at. However, chances are you're still in quirks mode or
almost-quirks mode. Did you follow the link Bergamot provided?

Signature

John

Bergamot - 30 May 2007 17:57 GMT
>> Your DOCTYPE triggers quirks mode.
>> http://www.hut.fi/u/hsivonen/doctype.html
[quoted text clipped - 3 lines]
> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
> "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

Out of all the possible choices, why did you pick that? You would be
better off with HTML 4.01 Strict. I'm not sure it matters since the URL
you posted <http://www.mavridis-hotel.gr/prices.php> doesn't follow any
one DTD anyway. It has both HTML and XHTML syntax as well as deprecated
attributes.

> which renders correctly after some minor changes and the table displays
> well.

That is yet to be seen. The online page is unchanged.

> Now I git 2 problems.
>
> 1)It's more generic. Since I 'm writting in php using befor DOCTYPE
> <?xml version="1.0" encoding="UTF-8"?> give a PHP error.

Didn't you read the page I pointed to? It specifically mentions what
effect the xml prolog has on rendering.

> 2) Now the div#middle which has height 100% isn`t shown as before

height is not a valid table HTML attribute.

Signature

Berg

Harris Kosmidhs - 31 May 2007 10:05 GMT
>> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
>> "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
[quoted text clipped - 4 lines]
> one DTD anyway. It has both HTML and XHTML syntax as well as deprecated
> attributes.

I have read quite a lot of articles saying that xHTML is the way to
write. Most (or maybe all?) of the newly created pages (e.g. oswd.org)
are xHTML. But reading this newsgroup lately I found out people here
suggesting HTML 4.01 strict.
So which one is right and/or better?

Have in mind that this wasn't my design. They gave me an already made
site but it was using tables, and most of all it was all messed up
inside the HTML. So I rewrote it.

> That is yet to be seen. The online page is unchanged.

I was testing it on my home computer. Anyway I uploaded it now.

>> Now I git 2 problems.
>>
[quoted text clipped - 3 lines]
> Didn't you read the page I pointed to? It specifically mentions what
> effect the xml prolog has on rendering.

Quite frankly didn't understand this about xml.

>> 2) Now the div#middle which has height 100% isn`t shown as before
>
> height is not a valid table HTML attribute.

I was referring to
#middle{
    float:left;
    width:150px;
    background-color:#F1EBDE;
    height:100%;
}
in my CSS.

I want his div to extend until bottom of the page. In quirks mode it
worked. Now?

And another thing I use in one page <table border="1">

Isn't that a deprecated attribute for xHTML? Then why does the
validation succeeds?
http://validator.w3.org/check?verbose=1&uri=http%3A%2F%2Fwww.mavridis-hotel.gr%2
Fprices.php


Thanks a lot for your answers...

Harris
Bergamot - 31 May 2007 15:47 GMT
>>> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
>>> "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
[quoted text clipped - 5 lines]
> I have read quite a lot of articles saying that xHTML is the way to
> write.

It is a myth. It is also off topic for this newsgroup. Search the
archives for ciwah and alt.html for more on the subject.

> Have in mind that this wasn't my design.
> I rewrote it.
> ...
> Quite frankly didn't understand this about xml.

It is always a good plan to understand the technology you are attempting
to use before jumping in the deep end. ;)

> #middle{
>     height:100%;
> }
>
> I want his div to extend until bottom of the page. In quirks mode it
> worked. Now?

You need to set height:100% on the html element as well as body. This
won't necessarily give you the results you want, though. That height
relates to the viewport, not the document.

Since your column widths are set to the size of the graphics at the top
of the page, you may want to use a background image (repeat-y) on the
body, instead. There are other ways to do it, but this is one of the
more simple ways to get the effect.

BTW, after looking at your CSS more closely I see why the table floats
under the navigation in Seamonkey - your widths don't jive. The 2 left
columns are each 150px wide. The content area is width:60%. In smaller
windows, 60% won't fit next to 300px so it drops under it. The total
adds up to less than 100% in larger windows, too, leaving empty space on
the right.

I suggest dropping both the float and explicit width on #main. Just set
a left margin to at least 300px and let it take whatever remaining space
there is. That may make for a pretty narrow column in smaller windows,
but it should be tolerable for most users.

Signature

Berg

 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2009 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.