Quackit Logo
HTML
CSS
Scripting
Database
Hosting
Design
XML
IMCreator - Free Website Builder

HTML style Tag

The information on this page is based on HTML version 4.01 (which is the current version of HTML). The next version, HTML 5, is currently being written. Here's a list of HTML 5 tags.

The HTML <style> tag is used for declaring style sheets within the head of your HTML document.

Each HTML document can contain multiple <style> tags. Each tag must be located between the <head> tags.

In HTML 5, the <style> tag can be used outside of the <head> tags as long as it contains the scoped attribute.

Example
<head>
<style type="text/css">
  h1 { color:#000099 }
</style>
</head>
Attributes:
Attributes specific to this tag:
AttributeDescription
nameDefines the name of the parameter.
typeSpecifies the style sheet language as a content-type (MIME type).
mediaSpecifies the device the document will be displayed on. Possible values:
  • all
  • braille
  • print
  • projection
  • screen
  • speech
Other Attributes:
AttributeDescription
dirSpecifies the direction of the text
langLanguage code
titleSpecifies a title to associate with the element. Many browsers will display this when the cursor hovers over the element (similar to a "tool tip").
Try it yourself!


Also see the HTML 5 version of HTML tags

Enjoy this page?

  1. Link to this page (copy/paste into your own website or blog):
  2. Link to Quackit using one of these banner ads.

Thanks for supporting Quackit!