Page 162 - Dig_CodeAI_V2.1_Class_7
P. 162

Viewing a Web Page

                  After creating and saving an HTML document, you need to open it into a web browser to view it.
                  To open an HTML document into web browser, open the folder in which you have saved the HTML
                  document and double-click it. Web page opens in your default web browser window.









                  HTML Tags and Attributes

                  In the previous class, you have learned various tags such <HTML>, <HEAD>, <TITLE> and <BODY>.
                  You have also learned attributes of these tags. Let us revise some of those tags and learn about
                  more tags of HTML.


                       Tags                                           Description
                                  The <HTML> tag tells the web browser that the text contained between <HTML>
                   <HTML>
                                  and </HTML> is a web page and can be viewed using a web browser.

                                  The <HEAD> tag represents the header area of the document. It contains information
                   <HEAD>
                                  about the document title, scripts and style definitions used in the document.
                                  The <TITLE> tag represents the title of the document and is used inside the <HEAD>

                   <TITLE>        tag. It appears on the title bar of the browser window. If you do not want to give
                                  title to your web page, you can skip it.
                                  The <BODY> tag defines that section of the HTML document which is visible on
                   <BODY>         the web browser. It contains all other tags that define the content presentation
                                  elements such as images, lists, tables, text and links to move between the webpages.

                  HTML5 provides different types of tags. For example, tag to create different types of headings, to

                  create a paragraph, to insert a line break, to add a horizontal line, etc. Let us learn about some of
                  them in detail.
                  The <Hn> Tag

                  Every  chapter  in  a  book  has  various  headings  and  sub-headings.  These  are  known  as  levels  of
                  headings.  HTML can define up to 6 levels of headings from H1 to H6. H1 is the first level of heading

                  and H6 is the last level of heading/sub-heading. Let us create a web page using heading tags.
                                                                  Output of the code:















                      160    DigiCode AI (Ver. 2.1)-VII
   157   158   159   160   161   162   163   164   165   166