Page 40 - DCAP202_Fundamentals of Web Programming
P. 40

Unit 3: HTML Command and Structure




          3.4.7 Controlling Font Sizes and Color                                                Notes

          Font Size Change - <font size=”+/-?”> </font>
          For an immediate change of font size with respect to the font size preceding it, this tag increase
          or decreases the size of the font by the number you specify. Eg: <font size=”-1">Some Text</
          font>
          Font Colour - <font color=”#??????”> </font>
          Change the colour of a few words or a section of text. The 6 question marks represent the hex
          color code,

          3.4.8 Preformatted Text <PRE>

          Refer 3.1.4

          3.4.9 Text Highlighting Tags

          Emphasis - <em> </em>

          Used to emphasize text, which usually appears in italics, but can vary according to your browser.
          Strong Emphasis - <strong> </strong>
          Used to emphasize text more, which usually appears in bold, but can vary according to your
          browser.

          3.4.10 Text Alignment

          The code to align text in HTML for a post or single page is <P ALIGN=direction>.When placing
          this code onto the page, you simply put where you’d like the text to be justified into where it
          says “direction” in the example.




              Task  Illustrate how to apply bold, italics, and control Font Sizes and Color.
          Self Assessment


          Fill in the blanks:
          11.  Using ........................... is helpful in situations where you just need one or two spaces in
               between characters or words for stylistic or aesthetic effect.
          12.  The tag ........................... change the colour of a few words or a section of text.
          13.  The code to align text in HTML for a post or single page is ...........................

          3.5 Text Effect

          There are a couple of simple text effects that can be produced just by using HTML tags. If you
          need more complicated effects you could use animated GIF images or JavaScript.








                                           LOVELY PROFESSIONAL UNIVERSITY                                   33
   35   36   37   38   39   40   41   42   43   44   45