Newbie Webmaster Free Graphics and Resources

Hosting
Domain Names
Templates
  
Graphics and Other Website News NewbieHangout Free Graphics and Resources Home Image, Graphics and Web Site Hosting Templates and Graphics Templates Free Linkware Graphics Graphics Tutorials Contact Us Graphic

Preformatted Text

Preformatted text differs from regular text in two important ways: 1. It will appear in a monospaced, or fixed-width font (making it look typewritten), and 2. it will appear in the browser window exactly as you typed it, including carriage returns and spaces.


<pre>  turns on preformatted text
</pre> turns off preformatted text
The following text is surrounded by the <PRE></PRE> tag set.
<pre>Dear Mom,
Would it be okay with you if I didn't come over today so I could clean my ... house?</pre>

And the display will look like this:

Dear Mom,
Would it be okay with you if I didn't come over today so I could clean my ... house?

Preformatted text is best used when displaying code, ASCII art, poetry, or anything else in which line returns and spaces are intentional. Remember, you must hit return on each line, or the text will trail off the browser window. (Anyhow, you should probably tell mom what you really want to do!)

Now, let's take a look at the above example again, but take it out of <pre>:

<p>Dear Mom,
Would it be okay
with you if I didn't come
                                                               over today
so I could
                                 clean my ... house?

It would display like this:


Dear Mom, Would it be okay with you if I didn't come over today so I could clean my ... house?

The line returns and spaces are ignored or downplayed in regular HTML.

Be careful with preformatted text, (in some browsers, it takes away lists and headlines), but it can be combined with other tags. You can make it bold or italic, for instance, and you can also build links into it, as shown below:

If your HTML reads like this:

<pre>I wonder
       if
         mom                    really
               b e  l i  e v  e s
 <b>me!!</b>

Maybe <a href="mailto:darla@darlasgraphics.com">I</a>
       should tell <i>her</i> the truth.</pre>
It will display like this:

I wonder if mom really believes me!!
Maybe I should tell her the truth.

Return to Help Index

Favorite Links

| Graphic Tutorials | HTML Tutorials | 3d Logo Generator | Background Tiles. | PSP Resource Index |
| Signature Graphics | Incredimail Letters | Code Generators | Java Scripts | Free Classifieds |


Newbie Hangout Logo

Copyright © 2001-2003 NewbieHangout.com. All Rights Reserved. No part of this website may be copied or reproduced. Permission is not given under any circumstances to use any of the graphics or art on this site for any purpose whatsoever without prior written permission.