Basic HTML Version

|  | Table of Contents |  | View Full Version

Page 87 - 2607_Trackpad_Pro_5.1_flipbook_C5
P. 87

    ATTRIBUTES

                     An  attribute  is used  to define  some  extra features  or properties  of an HTML  tag.  All
                     attributes have two parts: name and value. The ‘name’ is the property that you want to
                     set. The ‘value’ is what you want for the respective property.
                     Syntax to specify the attribute of any tag:
                     <tag_name attribute_name = “value”>

                               HTML COMMENTS

                     Comments are used to add notes or explanations within an HTML document. They help
                     the programmer by making it easier to understand and edit the document later. You can
                     add comments using a special tag, which looks like this: <!-- comment goes here -->.

                     For example, <!-- This is a comment in HTML -->

                               RULES FOR WRITING HTML CODES

                     There are some rules for writing HTML codes:
                       Container tags should always be closed properly.
                       Values given to the attributes should be enclosed within the double-quotes.
                       Tag name should not contain spaces.

                       There should be no space between < and > in a tag.
                       Tags must be nested correctly.

                               STRUCTURE OF AN HTML DOCUMENT

                     The structure of an HTML document is:

                      <!DOCTYPE HTML>
                      <HTML>
                        <HEAD>
                          <TITLE> The title of the webpage goes here. </TITLE>
                        </HEAD>

                        <BODY>
                           All the visible content of the webpage is documented here,
                             containing bulk of information. The section contains various
                             HTML tags defining  the structure  and layout  of the page
                             content.
                        </BODY>
                      </HTML>

                                                                                                 Introduction to HTML5  85

| 82 83 84 85 86 87 88 89 90 91 92 |