|
Posted by maya on March 16, 2007, 4:06 pm
Please log in for more thread options
Andy Dingley wrote:
>> this is doctype I was told to use for a site I'm building at work..
>>
>> <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
>> "http://www.w3.org/TR/html4/loose.dtd">
>
> Probably the wrong doctype to use. You should always use HTML 4.01
> Strict, unless there's a good reason not to. There aren't many good
> reasons.
>
> This particular doctype declaration _should_ make CSS rendering behave
> itself
> See <http://hsivonen.iki.fi/doctype/>
> but it's impossible to say for sure without a URL.
>
>> only problem is, in IE the layout gets totally screwed up!
>
> Smells like a quirks mode rendering problem.
>
>> everything becomes centered, the divs containing nav buttons gets
>> compressed, and buttons show up one on top of the other (it's a
>> horizontal nav, buttons run across top of pages..)
>
> That just sounds like broken code.
>
>> site is done with css, pretty standard css code, nothing out of the
>> ordinary (I think....;)
>
> Have you validated both HTML and CSS ? (Let me guess!)
> Have you validated both HTML and CSS _before_ asking any question to
> c.i.w.a.*?
>
>
>> can't provide url
>
> Can't provide a solution
>
interesting.. I put this,
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN"
"http://www.w3.org/TR/html4/strict.dtd">
which I got from here, http://htmlhelp.com/tools/validator/doctype.html (the top one..)
and problem goes away..
still don't fully get this doctype thing, but well, if this one works
will leave this one I guess..
thank you very much..
|