HTML Tags Directory
Here's a list of some of the most commonly used basic HTML tags and attributes along with their results. Tags are shown within angle brackets (<>) and attributes are not. To learn how to use them in context, click on the link to their relative section.
|
Feature |
Opening Tag | Closing Tag | Result |
|
Text (Click) |
|||
| Bold Text | <b> | </b> | Bold Text |
| Italic Text | <i> | </i> | Italic Text |
| Underlined Text | <u> | </u> | Underlined Text |
| Strikeout Text | <strike> | </strike> | |
| Subscript | <sub> | </sub> | Normal Subscript |
| Superscript | <sup> | </sup> | Normal Superscript |
| Change the font face | <font face="font name"> | </font> | Font is changed from default Times New Roman |
| Change the font size | <font size="size"> | </font> | Font size is changed from default 12pt |
| Change the font colour | <font color="color"> | </font> | Font colour is changed from default black |
| Line Break | <br> | None | Line Break |
| Paragraph Break | <p> | </p> (not strictly necessary) | Paragraph Break |
| Centre Text | <center> | </center> | Text is centred on page |
| Align Text | align=left/right/center | None | Text is aligned to your specification |
|
Images (Click) |
|||
| Show Image | <img src> | None | Displays an image within your page |
| Alternative Text | alt="text" | None | When image fails to show, text will be displayed |
| Bordered Image | border="size" | None | Adds a border around an image |
|
Links |
|||
| External Link | <a href="url"> | </a> | Links to another page |
| Anchor for Internal Link | <a name="name"> | </a> | Creates an anchor to link to within a page |
|
Body (Click) |
|||
| Background Image | background="image source" | None | Displays a background image on a page |
| Background Colour | bgcolor="color" | None | Changes the default background colour of a page |
| Text Colour | text="color" | None | Changes default text colour |
| Link Colour | link="color" | None | Changes default link colour |
| Active Link Colour | alink="color" | None | Changes default active link colour |
| Visited Link Colour | vlink="color" | None | Changes default visited link colour |

