Page 105 - Trackpad_ipro 4.1_Class6
P. 105

You can also set an image as the background of a web page by using the background-image
                 property of CSS in the following manner:

                 body{background-image:url(“background.jpg");}

                     TEXT PROPERTIES

                 CSS  provides  text  properties  that  are  used  to  change  the  appearance  of  the  text.  The  text
                 properties and their values used with the style attribute are given below:

                    Property                    Value                                 Description

                                                                      Specifies the text colour to be used on the
                 color             Name of the colour
                                                                      web page.
                 text-align        left, right, center, justify       Specifies the alignment of the text.
                                                                      Specifies the indentation of the first line of
                 text-indent       length in pixels or percentage
                                                                      the text.
                                   underline, overline or             Specifies the text effects like underline,
                 text-decoration
                                   strikethrough                      overline or strike-through.
                                   capitalize, uppercase,             Specifies the transformation of text into
                 text-transform
                                   lowercase and none                 uppercase, lowercase or title case.

                 Create an HTML5 web page by using the text properties.

                 <!DOCTYPE html>
                 <HTML>
                 <HEAD> <TITLE>Text Properties</TITLE>
                 <STYLE>
                 H1{font-family:Comic Sans MS; text-align:center;
                 text-decoration:underline;color:red}

                 </STYLE>
                 </HEAD>
                 <BODY>
                 <H1>Earth</H1>

                 <P style="font-family:Times  New Roman; text-transform:uppercase">  Earth
                 is the third planet from the Sun. It is the only planet that is known to
                 sustain life form. About 70% of the Earth’s surface ic covered with water,
                 rest of the earth surface is home to all the land dwelling animals.</P>

                 <HR>
                 <P style="font-family:Times New Roman; text-transform:lowercase">
                 Life on earth is sustained majorly due to the atmosphere. It consists of 4
                 layers, namely troposphere, stratosphere, mesosphere and thermosphere.</P>
                 </BODY>

                 </HTML>



                                                                                        HTML—An Introduction     103
   100   101   102   103   104   105   106   107   108   109   110