Page 83 - TP_Plus_v4_Class6
P. 83

<title> Using External Stylesheet</title>

                 <link rel="stylesheet" type="text/css" href="style.css">
                 </head>
                 <body>
                 Text with white colour and background colour is green
                 </body>

                 </html>
                 When you view the preceding web page in browser, you will get the following output:


























                 You can also use the 6 digits hexadecimal code in place of colour name. For example, the hexadecimal
                 code #000000 represents the black colour and #FFFFFF represents the white colour. Code for setting
                 background color for the whole web page is:

                 body{background-color: #000000;}
                 You can also set an image as background of a web page by using the background-image property of
                 CSS in the following manner:

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

                           Interdisciplinary Learning

                           #Science


                   Look at the web page and tick ( ) the tags used to create it.











                        <HTML>           <BODY>               <TITLE>               </BODY>

                                                                                                               #Activity




                                                                                      #Introduction to  HTML5 & CSS3  81
   78   79   80   81   82   83   84   85   86   87   88