Its not a question of how many tags are acceptable, its what is the nature of the errors. To be really technical, no errors are acceptable. On the other hand some kinds of errors don’t really affect how your page renders.
Looking at yours, at the minimum clean up the tag mismatch errors. Those are broken HTML structure and can cause problems in browsers like IE. The same for end tags for elements that are not open, and ID already defined. an ID can only occur once per page. If an ID needs to be used more than once on a page make it a class not an ID.
Its easy enough to add an empty alt=”” for a missing alt attribute, to change onClick to onclick, to close an img tag with /> instead of > Align attribute on img is deprecated, better to use CSS.
Thank you for your input, very interesting and will prove helpful.
The validation process would incorrectly mark some tags wrong…like <div class=”something”>. This would give a validation error.
From what I could see, most of the ID errors were not errors at all…they were not missed pid, they were really ID’s.
Image closing…should I use /> even if the full address link is given?
-Scott
in XHTML all tags that don’t have separate closing tags ( like <p></p> ) must be closed with /> examples – <br /> <img />
<div class="something"> is not going to give a validation error since it is valid code. What may not be valid is the match between the opening and closing div tags, and that is what can throw a browser (IE) off
<div id="one">
<div id="two">
<p>text here</div>
<p> more text here</p>
</div>
</div>
There are 2 opening div tags, 3 closing div tags, 2 opening p tags, one closing p tag. That is mismatched code, and that is what the validator points out to you.
My example is trivial and minor, but when you get 25 mismatched tags, often the browser is not going to display the page the way you want it to. Then, instead of fixing the underlying problems, people tend to create a workaround around the specific element that’s not displaying correctly, making increasingly complicated code.
Thank you. I will give closer examination.
-Scott