HTML Help... validation errors

liunx

Guest
Hello,<br />
<br />
Just trying to clean my html up before I start using the html as a template for the rest of my pages on my site. I'm getting some errors that I just don't understand, and I'm hoping someone can help me understand what the errors mean.<br />
<br />
Line 9, column 6: required attribute "TYPE" not specified (explain...). <br />
<STYLE>BODY {<br />
^<br />
Line 62, column 65: there is no attribute "HEIGHT" (explain...). <br />
...ER=0 CELLSPACING=8 CELLPADDING=3 WIDTH="738" HEIGHT="400" ><br />
^<br />
Line 64, column 46: there is no attribute "BACKGROUND" (explain...). <br />
... WIDTH="150" valign="top" background="http://www.stacyinthecity.com/Manhattan<br />
^<br />
Line 86, column 21: there is no attribute "NAME" (explain...). <br />
<form name="cityform"><br />
^<br />
Line 86, column 31: required attribute "ACTION" not specified (explain...). <br />
<form name="cityform"><br />
^<br />
Line 87, column 134: there is no attribute "VALUE" (explain...). <br />
...itymenu.selectedIndex].value;" value="GO" style="font-family: Verdana, Arial,<br />
^<br />
Line 123, column 9: document type does not allow element "NOSCRIPT" here; missing one of "APPLET", "OBJECT", "MAP", "IFRAME", "BUTTON" start-tag <br />
<noscript><br />
^<br />
The page in question is <!-- m --><a class="postlink" href="http://www.stacyinthecity.com/city/index.htm">http://www.stacyinthecity.com/city/index.htm</a><!-- m --><br />
<br />
Also, on my <!-- m --><a class="postlink" href="http://stacylynn.diaryland.com">http://stacylynn.diaryland.com</a><!-- m --> page, I'm getting an error of "unexpected `j'" on line 134, character 26.<br />
<br />
Thanks,<br />
Stacy<!--content-->Details from your Error list (<!-- m --><a class="postlink" href="http://validator.w3.org/check?uri=http%3A%2F%2Fwww.stacyinthecity.com%2Fcity%2Findex.htm&charset=%28detect+automatically%29&doctype=%28detect+automatically%29&ss=1&outline=1&sp=1">http://validator.w3.org/check?uri=http% ... ine=1&sp=1</a><!-- m -->).<br />
<br />
The <style> tag should be <style type="text/css"> instead.<br />
<br />
The errors for height and background are browser specific attributes. This does not work in all browsers. The background image will not show up in Netscape.<br />
<br />
For more information on forms, read [this document (<!-- m --><a class="postlink" href="http://www.w3.org/TR/html401/interact/forms.html">http://www.w3.org/TR/html401/interact/forms.html</a><!-- m -->)]. Every form must have an action that is followed when the submit button is pressed.<br />
<br />
There is no attribute "value" allowed with the <select> tag. I assume that this is browser specific code. <br />
<br />
Technically, I believe that <noscript> cannot appear inside a table. In real life I would ignore that error.<br />
<br />
You need a <meta name="description" content=" describe your site here "> tag in the <head> section. Search engines pay more attention to this than the keywords tag.<br />
<br />
You could update your !DOCTYPE from HTML 4.0 to HTML 4.01 if you want. All of the !DOCTYPE line MUST be in capital letters.<br />
<br />
<br />
<br />
You ought to check your CSS as well (<!-- m --><a class="postlink" href="http://jigsaw.w3.org/css-validator/validator?uri=http%3A%2F%2Fwww.stacyinthecity.com%2Fcity%2Findex.htm&warning=1&profile=css2">http://jigsaw.w3.org/css-validator/vali ... ofile=css2</a><!-- m -->).<br />
<br />
Some of the errors are browser specific code. <br />
<br />
The BACKGROUND: transparent url(file:///C|/My%20Documents/My%20Pictures/NYC/none) will not work on the web!<br />
<br />
you need a closing </style> tag, and you should enclose the style code in <!-- comment --> tags. The ending tag on javascript should be // --> instead.<br />
<br />
All numbers except zero must have the units stated: px, pt, em, or %.<br />
<br />
Check out the plain-English warnings, and correct where necessary.<br />
<br />
I would move the Style Sheet out to an external .css file, so that many pages can share the same file, and you only have to update it in one place. This also means that the style sheet only has to be loaded once per site visit, not once per page view, which speeds site delivery. This also saves Download <!--more--> bandwidth.<br />
<br />
<br />
<br />
The errors on your other page (<!-- m --><a class="postlink" href="http://validator.w3.org/check?uri=http%3A%2F%2Fstacylynn.diaryland.com%2F&charset=%28detect+automatically%29&doctype=%28detect+automatically%29&ss=1&outline=1&sp=1">http://validator.w3.org/check?uri=http% ... ine=1&sp=1</a><!-- m -->) are a lot more complex. This HUGE [153] amount of errors are caused simply by putting the !DOCTYPE in lower case, so that it is not recognised. The !DOCTYPE MUST be entirely in UPPER CASE. Replace it with something like:<br />
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"><br />
<br />
Your error list (<!-- m --><a class="postlink" href="http://validator.w3.org/check?uri=http%3A%2F%2Fstacylynn.diaryland.com%2F&charset=%28detect+automatically%29&doctype=HTML+4.01+Transitional&ss=1&outline=1&sp=1">http://validator.w3.org/check?uri=http% ... ine=1&sp=1</a><!-- m -->) will then be much easier to work with [21 errors].<br />
<br />
Missing type="text/css" from <style> tag.<br />
<br />
Missing </style> tag again. Actually it is in the wrong place, after </script>. Move it up.<br />
<br />
Change each & to be &amp; in every URL, to fix the entity errors.<br />
<br />
Check element nesting within the table. There are problems.<br />
<br />
Add type="text/javascript" to the <script> tags.<br />
<br />
<br />
This line:<br />
<script language="JavaScript">document.write("<a href=http://www.htmlforums.com/archive/index.php/"http://www.sitemeter.com/stats.asp?site=yuio1234" target=_top><img src="http://www.sitemeter.com/meter.asp?site=yuio1234&refer="+ escape(document.referrer)+"" border=0 alt="Site Meter"></a>");</script> </font></div><br />
<br />
should be:<br />
<script language="JavaScript" type="text/javascript">document.write("<a href=http://www.htmlforums.com/archive/index.php/\"http://www.sitemeter.com/stats.asp?site=yuio1234\" target=_top><img src=\"http://www.sitemeter.com/meter.asp?site=yuio1234&amp;refer="+ escape(document.referrer)+ "\" border=\"0\" alt=\"Site Meter\"></" + "a>");</script> </font></div><br />
<br />
You need to escape the quotes that are part of the HTML to separate them from the quotes that are part of the javascript, escape the ampersand as shown, as well as break up the closing </a> tag in order to "hide" it.<br />
<br />
<br />
The CSS errors (<!-- m --><a class="postlink" href="http://jigsaw.w3.org/css-validator/validator?uri=http%3A%2F%2Fstacylynn.diaryland.com%2F&warning=1&profile=css2">http://jigsaw.w3.org/css-validator/vali ... ofile=css2</a><!-- m -->) on this site are similar to those on the other site, especially missing </style> tag, and missing comment tags, missing units, and so on.<br />
<br />
Please check all of your other pages for similar errors. If you have a blank "template" that you use as a starter for your pages, then remember to also update and validate that as well.<br />
<br />
<br />
Edit for typos<!--content-->The first thing to do is to change all you upper case tags to lowercase ie<br />
<br />
<BODY> to <body>, 4.01 suggests u do this... would do more but getting ready for work.<!--content-->Thank you SO MUCH for your help. I will get to work and fix all of those errors! Thanks again!<br />
<br />
Stacy<!--content-->Why is it they reccomend that tags are written in lower case?<br />
<br />
I have started doing this about 1/2 year ago. I did it because I was gearing up for XML.<!--content-->Many months later....<br />
<br />
<br />
None of these errors have been corrected. In fact, there are more errors that ever.<br />
<br />
Makes you wonder why people actually ask for help if they then ignore the answers?<!--content-->The first thing to do is to change all you upper case tags to lowercase ie<br />
<br />
<BODY> to <body>, 4.01 suggests u do this<br />
Where does the 4.01 spec. recommend this? In fact, they use upper case tags throughout the spec. when they show examples of the tags being used. I know that XHTML requests lower case because XML is case sensitive, but HTML is not case sensitive.<br />
The !DOCTYPE MUST be entirely in UPPER CASE.<br />
I was also wondering where this is stated on the W3C website. I believe you, but I've never seen it.<!--content-->
 
Back
Top