Gernot Frisch wrote:
I have a site:
http://www.glbasic.com/bugs.htm
where 2 divs (class = "outer") overlap in Firefox. In IE it looks good
Your Doctype tries to be HTML 4.01 Transitional but fails. The "EN" at the
end of the URL indicates that the comments in the DTD are written in
English, not that the HTML document is written in English. Use the lang
attribute on the HTML element to specify the document language.
However, if you corrected your Doctype to read:
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
You have even more interesting problems. Some browsers treat the Doctype as
an intelligence test. "HTML 4.01 Transitional with no URL" causes those
browsers to decide that the author doesn't know how to write CSS, and thus
intentionally get things wrong.
So you should use the URL:
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">
Then you could use the markup validator and see you have machine detectable
syntax errors.
http://validator.w3.org/
However... HTML 4.01 Transitional contains lots of legacy junk that
shouldn't be used these days. HTML 4.01 Strict is almost always the best
choice of language to use for new documents.
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN"
"http://www.w3.org/TR/html4/strict.dtd">
This highlights a few more issues with your markup where you do things that
really should be handled by stylesheets.
Also, tables are not designed as layout tools.
http://allmyfaqs.net/faq.pl?Tableless_layouts
And using points for screen media font sizing is positively harmful:
* IE users can't resize text easily
* They entirely ignore user preferences
* Most systems are not correctly calibrated (so they don't translate points
to pixels correctly).
Generally speaking, its best to use percentage units for font sizing (with
the main body text being 100% - the user's preference).
There is little point in worrying about rendering glitches until you have
the syntactic errors fixed (since they are easy to detect and fix and could
be the cause).
--
David Dorward <http://blog.dorward.me .uk/> <http://dorward.me.uk/>
Home is where the ~/.bashrc is