HTML Tutorial Attributes

  • Attributes can be attached to certain tags
  • Attributes are used to provide additional information
  • Attributes are always identified in the opening tag
  • The Attribute must always be specified inside "quotation" marks, single 'quotations can also be used'
  • Attribute values are case-insensitive, lowercase should always be used.

HTML Attribute Example

<''tag'' ''attribute''="''value''">your content will be modified by the attribute tag</tag>

HTML Core Attributes

Attribute Value Description
class classname Specifies a class for the element
id id Specifies a unique id for the element
style style_definition Specifies an inline style for an element
title text  Specifies additional information about an element

HTML Tag Tips

HTML Comments can be inserted into the HTML code as statements or notes for your own reference so you can easily identify a particular section of your website. Comments are ignored by the browser, meaning they are not displayed and are only visible to you when editing. Comments are written like this: <!-- comment -->

Example: <!-— I last modified this section on Dec 2012 -->

comments powered by Disqus