You are here:  NetStrider » Tutorials » HTMLRef » Commands » P (Paragraph) «

HTML Reference Guide

Author: Randy D. Ralph.   In place March 1, 1999.   Copyright © 1999 NetStrider.   Presented as a public service.

BACK <P> Command next

Command Syntax:

<P command parameters>
  contains a paragraph
</P>

<P> - produces a simple paragraph break.

The command encloses, defines and contains an HTML document paragraph when used as a tag pair in conjunction with command parameters.  When used in conjunciton with command parameters, the command must be closed properly with the </P> tag.

In the Netscape browser it functions essentially the same as the <DIV> (division) command when used in conjunction with command parameters.

NOTE:  Much more commonly it is used as the simple unpaired command - <P> - which produces a line break with white space.  In this case, no paired command closing tag is required.

See also:  <BR>, <DIV>.

Command Parameters:

align="left | right | center"

Where:

  • left -
    aligns the paragraph text to the left margin.

  • right -
    aligns the paragraph text to the right margin.

  • center -
    aligns the paragraph text centered on the page margins.

lang="language code"

Where:

    The code used defines the language of the paragraph text using a two-letter country code from the ISO639 standard language abbreviations; i.e.,

    en = British English,
    es = Spanish,
    fr = French,
    de = German, etc.

    The language argument can be extended using the standard ISO3166 two-letter country code if desired; i.e.,

    en-US = American English,
    fr-CA = Canadian French, etc.

    This information may be useful to speech synthesizers and WWW search engines.

Examples:

<P align="right">
  a block of text to be aligned
  to the right margin
</P>

Enclosed text is aligned
to the right margin.
----------------------->

<P align="center">
  a block of text to be aligned
  centered between the margins
</P>

Enclosed text is aligned
in the center.
<----------------------->

<p lang="de">Freude sch&ouml;ner G&ouml;tterfunken, Tochter aus Elysium.</p>

Indicates that the enclosed text:

Freude schöner Götterfunken, Tochter aus Elysium.


is in German.

Note that this produces no visible effect on the rendering of the enclosed text but it may be of value to speech synthesizers or WWW search engines.

Return to Section M:R


Return to the List of Commands
Author: Randy D. Ralph.  In place March 1, 1999.  Copyright © 1999 NetStrider.  World Rights reserved.




Hosted by uCoz