Introduction to Text Structuring(continued-a)

 Text Structuring (Continued)

1. Text alignmen : like a chapter of book, the text in HTML document is structured into paragraphs. Each section of a chapter has several paragraphs.
         Most of the text we align left. However, some text we line towards the right or centre.
  Paragraph tag (<p></p>) : this tag is used to define a paragraph in a document. The paragraph beginning with <P> and end paragraph is closed with </P>.
           The paragraph can be aligned to the left,right, centre or justified using the align attribute. We can use align attribute with paragraph tag as:

Paragraph tag with
 align attribute

explanation

<P align=right>Text</P>align the text to the right side of the document.
<P align=centre>Text</P>align the text in the centre of the document.
<P align=left>Text</P>align the text to the left side of the document.
<P align=justify>Text</P>align the text from both the left and right margins.



Syeps to implement text alignment in HTML:

Step 1: open notepad for any other HTML editor and write the following code in it:



Step 2: Save the file as align.html.

Step 3: Now open the file in Google Chrome or any other web browser. It will look like as shown below:





Watch video


Please do subscribe to my YouTube channel

So that is about how to implement text alignment in HTML Web Page. Now click on the page3 to continue text structuring.



Comments