Web Quality - Important HTML Elements
To improve web quality,
are both important tags.
element
All HTML and XHTML pages should use the
The doctype defines which HTML version you are using and gives the browser important information so it can render your page faster and more consistently.
The document type declaration also lets validation software check the syntax of a page:
HTML 5
HTML 4.01 Strict, Transitional, Frameset
XHTML 1.0 Strict, Transitional, Frameset
XHTML 1.1
element
Even though the title is not a visible part of the web page, it is still important for improving site quality, because it is visible in the following places:
- Search engine listings
- The window title bar
- The user's bookmarks
Titles should be as short as possible and descriptive.
When a user searches for sites on the internet, most search engines display the site title in their results. Make sure the title matches the page content. That way users are more likely to visit your site by clicking those links.
When a user visits your site, the title is visible in the window title bar. Make sure the title still describes the site content even when the window is minimized.
After a user visits your site, the page title is stored in the history folder (the user may even bookmark the page). To make later visits successful, make sure the title clearly describes your site.
A good title:
Example
HTML Tutorial
XML Introduction
Bad heading example::
Example
Introduction
Chapter 1
Runoob Tutorial has a complete set of well-organized, easy-to-understand tutorials on HTML, CSS, JavaScript, DHTML, XML, XHTML, WAP, ASP and SQL, with many examples and source code.
Element
The element describes the top-level heading of a web page.
Since some browsers display the
element in a very large font by default, some web developers use the
element instead of the
element to show top-level headings. This does not affect readers, but confuses search engines and other software trying to "understand the page structure".
Make sure to use
for the top-level heading,
and
and for lower levels.
You can try to structure your page according to this template:
This is the main headingSome initial text This is a level 2 headingThis is some text. This is some text. This is some text. This is a level 3 headingThis is some text. This is some text. This is some text. This is a level 3 headingThis is some text. This is some text. This is some text. |
|---|
If you do not like the default heading font size, use styles or a style sheet to change it.