h6 tag (HTML 4.01)

heading

Topics

The hX tags are used to create headers on a page. H1 should be used for the most important header, while H6 should be used for the least important header. Browsers will render them in different sizes, based on their number, with H1 being rendered in the largest font and H6 in the smallest font.

 

Some people tend to not use the header tags, or use them in a wrong way, because they do not care for the way the tags are being rendered in their favorite browser, but that's wrong. You should always use the header text, mainly because a lot of search bots, especially Google's, use the information to figure out what your pages are all about. They prioritize text in header tags before the overall content of the page, so it's your best chance to emphasize what you think your page is all about.

 

The tags are as simple as it gets to use:

<h6>Header 6</h6>

If you don't like the specific look of one of the header tags, the solution is simple: Style it with CSS, using the font-family, the font-size and perhaps even the color property.

 

The align attribute

The align attribute allows you to specify to which direction text should be aligned. For instance, align="right" would align the text to the right side. However, the align attribute has been deprecated, and instead, you should use the CSS text-align property. For instance, like this:

 

<h6 style="text-align: right;">Right aligned text</h6>

Attributes

Attribute Deprecated Required Description
alignX align, text alignment 
class  space-separated list of classes 
dir  direction for weak/neutral text 
id  document-wide unique id 
lang  language code 
style  associated style info 
title  advisory title 

Events

Event Description
onclicka pointer button was clicked 
ondblclicka pointer button was double clicked 
onkeydowna key was pressed down 
onkeypressa key was pressed and released 
onkeyupa key was released 
onmousedowna pointer button was pressed down 
onmousemovea pointer was moved within 
onmouseouta pointer was moved away 
onmouseovera pointer was moved onto 
onmouseupa pointer button was released 



© htmlpedia.net 2008 - 2012