HTML was originally intended as a means of describing the content of a document, not as a means to make it appear visually pleasing. Semantic code returns to this original concept and encourages web designers to write code that describes the content rather than how that content should look.
There is no tool that can check for semantic code. It is a matter of looking at the code and seeing if it refers to colours, fonts or layout instead of describing what the content is.
Breadcrumbs present an important role to make website more search engine optimized.
Search results of correctly optimized site that have SEO friendly markup, work on its popularity much better than an advertisement, of cause, in a search results such sites are among first in the list.
Always declare the document type as the first line in your document:
<!DOCTYPE html>
If you want consistently with lower case tags, you can use:
<!doctype html>
Use Correct Document Type
Use Lower Case Element Names
Looking bad:
<section>
<p>This is a paragraph.
<p>This is a paragraph.
</section>
Close All HTML Elements
Close Empty HTML Elements
Looking good:
<section>
<p>This is a paragraph.</p>
<p>This is a paragraph.</p>
</section>
The slash (/) is required in XHTML and XML.
If you expect XML software to access your page, it might be a good idea to keep it.
Looking bad:
<div CLASS="menu">
Use Lower Case Attribute Names
Quote Attribute Values
Looking good:
<div class="menu">
This will not work, because the value contains spaces:
<table class=table striped>
This will work:
<table class="table striped">
Always use the alt attribute with images. It is important when the image cannot be viewed. Also always define image size. It reduces flickering because the browser can reserve space for images before they are loaded.
<img src="html5.gif" alt="HTML5" style="width:128px;height:128px">
Image Attributes
Spaces and Equal Signs. Blank Lines and Identation. Avoid Long Code Lines.
Short comments should be written on one line, with a space after <!-- and a space before -->:
<!-- This is a comment -->
But long comments, spanning many lines, should be written with <!-- and --> on separate lines:
<!--
This is a long comment example. This is a long comment example.
This is a long comment example. This is a long comment example.
-->
HTML Comments
Use simple syntax for linking style sheets (the type attribute is not necessary):
<link rel="stylesheet" href="styles.css">
Short rules can be written compressed, on one line, like this:
p.into {font-family:"Verdana"; font-size:16em;}
Long rules should be written over multiple lines:
body {
background-color: lightgrey;
font-family: "Arial Black", Helvetica, sans-serif;
font-size: 16em;
color: black;
}
Style Sheets
Style Sheets