Search code examples
htmlw3cw3c-validation

W3C HTML5 Validation Issues


HTML WITH ERRORS

<meta description="keywords" content="Quekett, restaurant, Pub, Isle of Wight, Fresh, Lobster, Crab, Seafood, Bembridge, Food, Dining, Breakfast, Lunch, Dinner, Bed and Breakfast, B&amp;B">



<link href="CSS/basic.css" rel="stylesheet" media="screen and (-webkit-device-pixel-ratio: 1.5)">

W3C Validation Issues

Just attempted to validate a HTML5 site I'm building and have cleared out the majority of the issues but stuck with these 4 lingering issues below any ideas on what possible fixes to get rid of these?


Solution

  • Warning 1:

    "Attribute description not allowed on element meta at this point"

    means, that you are not allowed to have an attribute called description. Examples of valid meta-tags can be found here: http://www.w3schools.com/tags/tag_meta.asp

    Your tag would then look like:

    <meta name="keywords" content="Quekett, restaurant, Pub, Isle of Wight, Fresh, Lobster, Crab, Seafood, Bembridge, Food, Dining, Breakfast, Lunch, Dinner, Bed and Breakfast, B&B">
    

    The second Warning is a consequence of warning 1, you can ignore that if you have fixed number 1.

    Warning 3: I don't understand what exactly you want there, so I give you the w3c recommodations on media queries: http://www.w3.org/TR/css3-mediaqueries/

    Warning 4: You have a reserved HTML Entity in your text/link. You have to escape that. Escaping in HTML means that you escape ith with the charactes &, followed by a code, and ending with ;. So & gets escaped to &amp; since the code for the ampersand is amp.

    Source: http://www.w3schools.com/html/html_entities.asp

    There is an interesting Blog about the usefullness of 100% valid HTML http://www.codinghorror.com/blog/2009/03/html-validation-does-it-matter.html