HTML | Tags | Paragraph & Align

html paragraph

Paragraph:

The <p> element offers another way to structure your text. Each paragraph of text should go in between an opening <p> and closing </p> tag.

Elements can all carry the universal attributes:

  • align
  • class
  • id
  • style
  • title
  • dir
  • lang
  • xml:lang

<DOCTYPE HTML–
<p> This is First Paragraph </p>
<p> This is Second Paragraph </p>
<p> This Is Third Paragraph </p>
</html>

Align:

The align  attribute indicates whether the heading appears to the left, center, or right of the page (the default is the left).

The align attribute has been replaced by two CSS properties: the text – align property to align text, and float to position larger items on a page.

<DOCTYPE HTML–
<h1 align=”left”> Text Align Left </h1>
<h1 align=”center”> Text Align Center </h1>
<h1 align=”right”> Text Align Right </h1>
</html>

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s