|
|
Learning HTML - Text Controlling Tags Part 1In this section, we shall look at
The Paragraph Tag The paragraph tag is <P>. You should always end the paragraph with </P> even though it is not required. The important Attribute of this tag is ALIGN which can take one of the four values; "LEFT", "RIGHT", "CENTER", "JUSTIFY". LEFT is the default value. <P> is aligned to the left.</P><P align="right"> is aligned to the right.</P> <P align="center"> is centrally aligned.</P> When "JUSTIFY" value is used, the browser inserts blank spaces between words so that the text is justified equally at both the ends quite like this very paragraph (note the difference between this para and the others). This is preferred by people who like to have symmetry in their document layout. You should be able to make out the difference between the justifications of this paragraph and the ones above and below it. Yes? <DIV> tag <DIV align="left"> aligns elements inside it, to the left.</DIV>
<DIV align="right"> aligns elements inside it, to the right.</DIV>
<DIV align="center"> aligns elements inside it, to the center.</DIV>
<CENTER> tag Blockquote If you wish to introduce some large body of text and make it stand out from the rest, you should put it between <BLOCKQUOTE> - </BLOCKQUOTE>. The enclosed text will be indented from the left and right margins and also adds space at the top and bottom quite like this paragraph. Many web designers have been guilty in the past of placing various HTML elements inside <BLOCKQUOTE> tags to take advantage of the indenting. This is not a good practice and should be avoided. A better choice would be to use Style Sheets. Address Hubba Hubba Street<BR> Aaron City<BR> In Internet Explorer and Netscape Communicator, the text inside <Address> tag is italicized. Preformatted Text Text within <PRE> - </PRE> is rendered along with any spaces, tabs, returns. So there is no need of using the <BR> tag and I can introduce tabs quite like this or spaces like this. Text within these tags is displayed as monospace (Courier Font in Windows). A monospace font is one in which the width of each character whether its the wide 'm' or the thin 'i' is equal. Now play with the code:
Page contents: Learning html - online html learning tutorial - learning html for free online - formatting text on web pages
Page URL: http://www.webdevelopersnotes.com/tutorials/html/ learning_html_text_controlling_tags_part_1.php3
|
|