Flavicon code always flagged by validator

Janitor_Willie

New Member
http://validator.w3.org/ keeps telling me "document type does not allow element "link" here". The element named above was found in a context where it is not allowed. This could mean that you have incorrectly nested elements -- such as a "style" element in the "body" section instead of inside "head" -- or two elements that overlap (which is not allowed).

Anything look wrong about this code? The flavicon appears perfectly when loading my page. Just a validator.w3.org flagged error.

<link rel="shortcut icon" href="favicon.ico" />
<link rel="icon" type="png" href="favicon.ico" />
 

chrishirst

Well-Known Member
Staff member
The error will be earlier in the source, the validator only flags where an 'error' shows up, not hecessarily where it is.
 

Janitor_Willie

New Member
I ran a validation report on tmz.com and it found a ton of errors. It almost seems par for the course to have errors.

Let me ask you this... Does having errors or a lot of errors hurt your SEO?
 

chrishirst

Well-Known Member
Staff member
I ran a validation report on tmz.com and it found a ton of errors. It almost seems par for the course to have errors.
Not really, it's simply that a 'validator' is for HTML what a 'spelling and grammar check' is for word processors. ....

...Sometimes the 'rules' can be broken with no detriment to the end result.


Let me ask you this... Does having errors or a lot of errors hurt your SEO?
No!

If the layout isn't 'broken' due the 'errors', it really doesn't matter that much.
 
Top