Formatting the textNow we'll see the basic rules of text formatting.Force a line break (carriage return)Put the <BR> tag in the desired point.
Who's that girl?<BR>She's so pretty...
Who's that girl?
She's so pretty... Put a single empty linePlace two <BR> tags.
I've lost my glasses.<BR><BR>Help!
I've lost my glasses.
Help! To have n empty lines, insert (n+1) <BR> tags. Write bold textThe bold text has a thicker font.Type the text between the <B> tag and the </B> tag. Mike has a <B>big</B> house. Mike has a big house.
Write italic textThe italic text has a sloping font.Type the text between the <I> tag and the </I> tag. Peter has a <I>Stratocaster</I> guitar! Peter has a Stratocaster guitar!
Quote some textIf you need to quote (cite) a portion of text,put it between the tags <BLOCKQUOTE> and </BLOCKQUOTE>. It will appear lightly shifted to the right (indented). She told me:<BLOCKQUOTE>It was a dark and stormy night...</BLOCKQUOTE> She told me:
It was a dark and stormy night... Draw an horizontal linePut the <HR> tag.
This is a line (Horizontal Rule). It is a content separator.<HR>
This is a line (Horizontal Rule). It is a content separator.
Preformatted textThe other way to display a text with spaces, indentation, and blank lines, is to use the preformatted text.The preformatted text uses a monospace font ( a fixed-width font, as Courier ). Type the whole text between the <PRE> tag and the </PRE> tag. What you type is what you get. Tip : short text lines looks better. <PRE> There was a little sun in the midnight There was a little moon in the morning </PRE> There was a little sun in the midnight There was a little moon in the morning Style combinationsThe formatting styles (bold, italic, blockquote, preformatted) can be combined together.To make a combination, write one tag block inside the other.
This <I><B>cell phone</B></I> costs <B>$ 199</B>.
This cell phone costs $ 199.
Special charactersSome special characters, as & , © , € and so on, have an equivalent representation (reference):This table shows the most used and the equivalents:
To write a special character, use the equivalent entity:
This is the "ampersand" character: &
This is the "ampersand" character: &
Sometimes you need to insert a fixed length space. You can display a space of n characters writing n times | Spring Summer Autumn |<BR><BR> | Spring Summer Autumn | | Spring Summer Autumn |
| Spring Summer Autumn | Comment the codeWe can add a comment into the code, writing it between <!–– and ––>Note:
<P> This is the first chapter:... </P> <!-- First chapter ends here --> <!-- Second chapter begins here --> <P> This is the second chapter:... </P> This is the first chapther:... This is the second chapther:... Next page : how to write lists. |