Web Developer's Virtual Library: Encyclopedia of Web Design Tutorials, Articles and Discussions


WDVL Newsletter

Active Server Pages
JSP/Java Servlets
Microsoft SQL Server
Daily Backup
Dedicated Servers
Streaming Audio/Video
24-hour Support    

jobs.webdeveloper.com

Hiermenus


e-commerce
Partner With Us















Developer Channel
FlashKit.com
JavaScript.com
JavaScriptSource
Developer Jobs
ScriptSearch
StreamingMediaWorld
Web Developer's Journal
Web Developer's Virtual Library
WebDeveloper.com
Webreference
Web Hosts
XMLfiles.com

internet.com
IT
Developer
Internet News
Small Business
Personal Technology

Search internet.com
Advertise
Corporate Info
Newsletters
Tech Jobs
E-mail Offers


Notes to "Introduction to Web Design | Basic HTML Body Tags "

1 <P> Indicates a new paragraph and instructs the browser to add a blank line. Takes optional alignment parameters of LEFT, RIGHT or CENTER to align the paragraph.

W3C
align has been deprecated in favor of Style Sheets.

Deprecated Example:

   <P align="right">A paragraph covering several lines...

CSS Example:

	<HEAD><TITLE>How to Right Align Text</TITLE>
    	<STYLE type="text/css">
     	P.mypar {text-align: right}
    	</STYLE>
   	<BODY>
    	<P class="mypar">A paragraph covering several lines...

CSS Example of right aligning a series of paragraphs by grouping them with the DIV element:

	<DIV align="right">
    	<P>...This is the first paragraph...
    	<P>...This is the second paragraph...
    	<P>...This is the third paragraph...
   	</DIV>

Or, since the text-align property is inherited from the parent element in CSS, you can use:

	<HEAD><TITLE>How to Align Text</TITLE>
    	<STYLE type="text/css">
     	DIV.mypars {text-align: right}
    	</STYLE>
   	<BODY>
    	<DIV class="mypars">
    	<P>...This is the first paragraph...
    	<P>...This is the second paragraph...
    	<P>...This is the third paragraph...
    	</DIV>
Finally, to center the entire document with CSS:
   	<HEAD><TITLE>How to Align the Entire Document</TITLE>
    	<STYLE type="text/css">
     	BODY {text-align: center}
    	</STYLE>
   	<BODY>
    	The body of the entire document is centered...
   	</BODY>

2 <HR> - This tag creates a horizontal line across the screen. By default the line will span the entire width of the document according to the specifications of BLOCKQUOTE and LIST tags. However, you can modify the look of the line by using any of the following attributes. ALIGN may equal LEFT, RIGHT, or CENTER. SIZE may equal some pixel value. WIDTH may equal some pixel value or some percentage of the document width. NOSHADE will turn off the beveling look. COLOR may equal some color hexvalue.

W3C
align : deprecated
noshade: deprecated
size=length: deprecated
width=length deprecated
color: is not specified as an attribute of <HR>

Return to "Introduction to Web Design | Basic HTML Body Tags "



Up to => Home / Authoring / HTML / Tutorial




Jupiter Online Media: internet.comearthweb.comDevx.commediabistro.comGraphics.com

Search:

Jupitermedia Corporation has two divisions: Jupiterimages and Jupiter Online Media

Jupitermedia Corporate Info


Legal Notices, Licensing, & Permissions, Privacy Policy.

Web Hosting | Newsletters | Tech Jobs | Shopping | E-mail Offers