EchoEcho.Com Homepage
Web Hosting - As Reliable As It Gets!
   Home > Tutorials > HTML > Text


 Tutorials 
 D-Zine Articles 
 Online Tools 
 Free Resources 
 References 
 Quiz 
 Hosting 

















  HTML Text :
TEXT LAYOUT








These tags will let you control the layout.

HTMLEXPLANATION
<p>text</p>Adds a paragraph break after the text.
(2 linebreaks).
<p align="left">text</p>Left justify text in paragraph.
<p align="center">text</p>Center text in paragraph.
<p align="right">text</p>Right justify text in paragraph.
text<br>Adds a single linebreak where the tag is.
<nobr>text</nobr>Turns off automatic linebreaks
- even if text is wider than the window.
text<wbr>Allows the browser to insert a linebreak
at exactly this point
- even if the text is within <nobr> tags.
<center>text</center>Center text.
<div align="center">text</div>Center text.
<div align="left">text</div>Left justify text.
<div align="right">text</div>Right justify text.


Example: the difference between layout tags:
RESULTHTML
Hello world- a linebreak does not insert a linebreak in HTML


you will need

to insert

special tags

that will insert
linebreaks
where
you want it!

Another method is to write a sentence, that is long enough to force a linebreak.

This option can however be turned offwith the nobr-tag.unless a wbr is used to force it!


You can also center
And turn the center off
And on!
Go left!
Go right!
Hello world -
a linebreak does not
insert a linebreak in HTML

<p>you will need</p>

<p align="right">to insert</p>

<p align="left">special tags</p>

that will insert<br>
linebreaks<br>
where<br>
you want it!<br>
<br>
Another method is of course to write a sentence, that is long enough to force a linebreak.<br>
<br>
<nobr>This option can however be turned off<wbr>with the nobr tag,<wbr>unless a wbr is used to force it!</nobr>

<center>You can center</center>
And turn the center off
<div align="center">And on!</div>
<div align="left">Go left!</div>
<div align="right">Go Right!</div>

Note in particular the difference between the <p> and the <div> tags. The <div> tag allows you to justify content without being forced to add a double linebreak.

Also, note that these alignment tags are not limited to text. They work on text, images, applets or whatever it is that you insert on the page.


 << PREVIOUS
BACK TO MENU >>  
















DEVELOPER TIP!
FACT:
Most free graphic sites offer graphics that you can browse at random.
TIP:
Our online tool lets you select each of our 3000 graphics in any color you want.
And you can see how backgrounds, buttons and dividers work together at the same time.





     "Better Than Books - As Easy As It Gets!"


On EchoEcho: D-Zine Articles | Tutorials | Online Tools | Free Resources | References | Quiz | HostingAbout EchoEcho