W3 says </head><body> are errors? Y?

admin

Administrator
Staff member
Hello,

I'm trying css and find it VERY trying, What the h--- is going on.

I have a very basic page yet w3c found 12 errors. I've gotten it down to 3 but but but....

How the hell can.....

charset=UTF-8" />

...be an error? And...

</head>
<body>

....be 2 errors?

and how do I center the 'copyright' text at the bottom of the page? (No error there but I want it centered). W3c suggested don't use 'p style', use 'object' or 'map' instead. Yet 'p style' works else where on the page and doesn't show up as an error. Hmmmm....help.

You can veiw source at: <!-- m --><a class="postlink" href="http://www.thereidpuzzles.com">http://www.thereidpuzzles.com</a><!-- m --> < Warning : Looks like crap compared to my non-css site.You're using a HTML 4.01 doctype. Therefore the "<meta.... />" is an error as the " />" closing of an unpaired tag is for XHTML. Those errors may be causing the </head><body> to not get parsed correctly by the validator.

BTW, I'd recommend using the HTML 4.01 Strict doctype unless there is a specific reason to use the "loose" one for your site.Start by switching your doctype from the HTML 4.01 Transitional doctype to XHTML 1.0 Transitional. The forward-slashes on the meta tags are only needed in XHTML.

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


EDIT: NogDog's the quicker typer :)XHTML&trade; 1.0 transitional is the least most cross browser version, followed by HTML 4.01 transitional, XHTML&trade; 1.0 Strict and then html 4.01 Strict. Use HTML 4.01 Strict.Ok, I tried using toicontien's code (thank you) but my server over-rides it and puts the 'loose' back. So, I tried to remove the / from /> in the metas and was again over-rided. So, that wont work, unless I tell my server (they are constantly updating and may not know.) But I don't wanna say anything until I'm sure, I'ld rather look dumd out here first.

As for the center....agggghhhh! I used 'object style' instead of 'p style' and the errors were gone! (items are title and copyright footer) However, the items were NOT centered so I put the 'p' back. Must I have an error so the page looks right? Sure looks that way. Any thoughts out there? Or do you think that will also be resolved when the Doc type is corrected, (if it can be)?

veiw <!-- m --><a class="postlink" href="http://www.thereidpuzzles.com">http://www.thereidpuzzles.com</a><!-- m -->


Thanks so much for the replies you peopleses!Originally posted by Sir Jake
Ok, I tried using toicontien's code (thank you) but my server over-rides it and puts the 'loose' back... Why (and more importantly how) is your server changing your code?How? Automatic I guess (in the programing)....why? So some don't mess it up and go back to them for help over and over again. Some servers don't allow anything to be added (or-) from the head at all. I've ask about switching to another server out here before and got no response. So....oh well. Any ideas?Find a different Web host. These guys obviously think you're a Front Page or Dreamweaver lacky. Find a company that lets you screw up and lets you do it right.Please list the name of this host so that we can avoid it. :) Thanks.I've ask about switching to another server out here before and got no response. So....oh well. Any ideas?

Anyone know of any servers that.... lets you screw up and lets you do it right. ?I am confused... should I use xhtml doctype when I have html source?

and would it be the same when I am using some php strings?

cus I plan to get everything working in html first, and then change the extension to php and add some php strings for the lastOriginally posted by Sir Jake
Anyone know of any servers that.... ? I don't know if it is appropriate here but you cna send me a private message and I'll tell you what I use.Triumph,

Already did, if you didn't (don't) get lemme know I'll do it again.

Thanx.Originally posted by Siddan
I am confused... should I use xhtml doctype when I have html source?

and would it be the same when I am using some php strings?

cus I plan to get everything working in html first, and then change the extension to php and add some php strings for the last

Only if use the XHTML DOCTYPE if you're using XHTML. The DOCTYPE, which states the language and version and points to the DTD, should correspond, obviously, to the markup language you are using. The DTD defines the rules of the markup language, so it'd be inane to using anything other then what you're using. I'd recommend to you to use HTML 4.01 Strict unless you really know what you're doing. And PHP is server side, it shouldn't affect the markup at all.ok thanks. I will try go for that then
 
Back
Top