Electric Type

Multimedia

About Us

News

Help

Authoring   HTML Basics
Teletype

<tt> opens teletype
</tt> ends teletype

Preformatted text is just that - preformatted; the line breaks are determined by hard returns (hitting the return key). If you don't indicate line breaks, you won't get any. The preformatted text will just trail off the right-hand side of the page. Tel etype, however, is treated like normal text. It can accommodate formatting tags, like <p> and <br>, and will automatically wrap, in accordance with the width of the browser window.

The HTML for teletype would look something like this:

<tt>Mom and Dad,

<p>Work is good. Thanks for the shirts. I'm not sure how to tell you this, but, well, I'm quitting my job to pursue professional broomball. This Web stuff wasn't really my thing.

<p>Could you send a few extra dollars my way? I have an appointment to get my shoulder reset, and they make you pay up front.

<p>Your loving son,<br>
Luke </tt>

And would look like this:

Mom and Dad,

Work is good. Thanks for the shirts. I'm not sure how to tell you this, but, well, I'm quitting my job to pursue professional broomball. This Web stuff wasn't really my thing.

Could you send a few extra dollars my way? I have an appointment to get my shoulder reset, and they make you pay up front.

Your loving son,
Luke

Since teletype is treated like normal text, it can be modified by other font tags or integrated into a line of normal text without being pushed onto a new line.

So if your HTML looked like this:

<p>My programs used to say <tt>"Hello, world!"</tt> Now they say <tt>"Bite me!"</tt>
Your page would look like this:
My programs used to say "Hello, world!" Now they say "Bite me!"

So, basically, teletype is much like preformatted text, but with less hassle. You'll still want to use preformatted text when you honestly need to format the text. But if you're just looking for that retro-typewriter look, teletype is the way to go.


Got a handle on it? Now try it yourself.



Learn More
View Source
Paragraphs
Headlines
Links
Mailtos
Comment tags
Bold/Italics
Font color
Font size
Teletype
Blink
Preformatted text
Background image
Background color
Blockquotes
Line breaks
Aligning text
Adding/Aligning Images
Ordered lists
Unordered lists
Definition lists
Image borders
Wrapping text



Tutorials  

Authoring  

Teaching Tools  

Backend  

Multimedia  

Design  

E Business  

User Blogs

Screen Shots

Latest Updates

Contact Us

Valid HTML 4.01!
Valid CSS!

Breadcrumb

© ElectricType
Maintained by My-Hosts.com
Site map | Copyright | Disclaimer
Privacy policy | Acceptable Use Policy
Legal information.