Quote:
Originally posted by robot180
Can someone explain what w3c validation is?
I was told to put this code at the top of my html documents in my website.
Code:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0
Transitional//EN" "http://www.w3.org/TR/REC-
html40/loose.dtd">
Then I was told to go to this website and enter the URL of my website. It said there was 29 errors even though I made sure there were no errors in the entire website.
validator.w3.org
The errors sounded so rediculous. I didn't know that you can't use the <br /> tag. It said there is no such thing as the "bgcolor" attribute of the <body> tag. It said there is no "name" attribute of the <a> tag. These sound so rediculous.
Can someone help me out?
|
Actually, <br /> is valid, I think for only XHTML though (it's the surpasser (sp?) of HTML according to the W3C site, and W3Schools.com).
The name attribute has been replaced by "id", and for coloring (like the bgcolor tag), the standard is becoming CSS (style sheets) now (like what Adam said). Except for style sheets, to make it compliant, I think you need to use hex numbers (like #000000 = black, #FFFFFF = white, #808080 = dark grey).
CSS isn't dependent upon what language you use (HTML or XHTML). I personally think you should always make it compliant with W3C standards, but that's just my personal opinion. My
FIRST site is compliant in both XHTML and CSS, which makes it better for other browsers to view it in, besides IE 6.