X
HOME HTML CSS JAVASCRIPT SQL PHP JQUERY XML ASP.NET MORE...
REFERENCES | EXAMPLES | FORUM | ABOUT

HTML <dir> Tag. Not Supported in HTML5.


Example

A directory list:

<dir>
  <li>html</li>
  <li>xhtml</li>
  <li>css</li>
</dir>

Try it Yourself »

Definition and Usage

The <dir> tag is not supported in HTML5. Use CSS instead.

The <dir> tag is used to list directory titles.


Browser Support

Element
<dir> Yes Yes Yes Yes Yes


Tips and Notes

Tip: Use CSS to style lists! In our CSS tutorial you can find more details about styling lists.


Differences Between HTML 4.01 and HTML5

The <dir> tag is not supported in HTML5.


Optional Attributes

Attribute Value Description
compact compact Not supported in HTML5.
Specifies that the list should render smaller than normal



Your suggestion:

Close [X]

Thank You For Helping Us!

Your message has been sent to W3Schools.

Close [X]
Search w3schools.com:

WEB BUILDING

Download XML Editor FREE Website BUILDER Free HTML5 Templates FREE Website Templates Free HTML Templates

SHARE THIS PAGE

facebook