Introduction
- What is BBCode?
- BBCode is a special implementation of HTML. Whether you can actually use BBCode in your posts on the forum is determined by the administrator. In addition you can disable BBCode on a per post basis via the posting form. BBCode itself is similar in style to HTML, tags are enclosed in square brackets [ and ] rather than < and > and it offers greater control over what and how something is displayed. Depending on the template you are using you may find adding BBCode to your posts is made much easier through a clickable interface above the message area on the posting form. Even with this you may find the following guide useful.
Text Formatting
BBCode includes tags to allow you to quickly change the basic style
of your text. This is achieved in the following ways:
- How to emphasize text
- To emphasize a piece of text enclose it in [em][/em], e.g.
This is [em]Great![/em]
- would give This is Great!
- How to strongly emphasize text
- To strongly emphasize text use [strong][/strong], e.g.
[strong]Hello[/strong]
- will become Hello
- How to hide text
- To hide text form normal view use the [spoiler][/spoiler] tag. A reader would need to highlight the hidden text to see the passage. For example:
[spoiler]This is a spoiler![/spoiler]
- would produce This is a spoiler!
- How to change the text colour
- Changing the colour of text is achieved by wrapping it in [color=][/color]. You must specify a recognised colour name or the tag will be ignored. e.g.
[color=red]Hello![/color]
- Will output Hello! The colours that are accepted are:
black,
navy,
blue,
green,
teal,
lime,
aqua,
maroon,
purple,
olive,
gray,
silver,
red,
fuchsia,
yellow, and
white.
- Keep in mind that how the output appears will depend on the viewers browser and system.
- How to change the text size
- Changing the text size is achieved by wrapping it in [size=][/size]. One can use a specific sized font. e.g.
[size=medium]MEDIUM[/size]
- will be MEDIUM. The following sizes are accepted:
xx-small,
x-small,
small,
small,
large,
x-large, and
xx-large
- Relative sizes can also be used:
smaller, and
larger.
- Note that this tag is dependent on the viewers browser and the template the user has selected.
- Can I combine formatting tags?
- Yes, of course you can, for example to get someones attention you may write:
[size=small][color=red][strong]LOOK AT ME![/strong][/color][/size]
- this would output LOOK AT ME!
- We don't recommend you output lots of text that looks like this though! Remember it is up to you, the poster, to ensure tags are closed correctly. For example the following is incorrect:
[strong][code]This is wrong[/strong][/code]
- and can result in the tags being ignored or the text being removed.
Quoting and outputting fixed-width text
- Quoting text in replies
- To quote some text, enclose the text in [quote][/quote] tags. When you view the message it will simply show the text within a quotation block. e.g.
[quote]Text to be quoted.[/quote]
- would become
-
Text to be quoted.
- You can also reference the quote to a person by enclosing the quote in a [quote=""][/quote] block. For example,
[quote="Mr. Blobby"]The text Mr. Blobby wrote would go here[/quote]
- The resulting output will automatically add "Mr. Blobby wrote:" before the actual text.
Mr. Blobby wrote:
The text Mr. Blobby wrote would go here
- Remember you must include the quotation marks "" around the name you are quoting, they are not optional.
- Outputting code or fixed width data
- If you want to output a piece of code or in fact anything that requires a fixed width, e.g. Courier type font you should enclose the text in [code][/code] tags, e.g.
[code]echo "This is some code";[/code]
- Would produce:
echo "This is some code";
- All formatting used within [code][/code] tags is retained when you later view it.
Creating Links
- Linking to another site
- BBCode supports a number of ways of creating URIs (Uniform Resource Indicators) better known as URLs.
Please notice that the link opens in the same window or a new window depending on the users browser preferences.
- As with all the BBCode tags you can wrap URLs around any of the
other tags such as [img][/img] (see next entry),
[strong][/strong], etc.
- As with the formatting tags it is up to you to ensure the correct open and close order is following, for example:
[url=http://www.google.com/][img]http://www.google.com/intl/en_ALL/images/logo.gif[/url][/img]
- is not correct which may lead to your post being deleted so take care.
Showing images in posts
- Adding an image to a post
- BBCode incorporates a tag for including images in your posts. Two very important things to remember when using this tag are: many users do not appreciate lots of images being shown in posts and secondly the image you display must already be available on the internet (it cannot exist only on your computer for example, unless you run a webserver!). To display an image you must surround the URL pointing to the image with [img][/img] tags. For example:
[img]http://www.google.com/intl/en_ALL/images/logo.gif[/img]
- As noted in the URL section above you can wrap an image in a [url][/url] tag if you wish, e.g.
[url=http://www.google.com/][img]http://www.google.com/intl/en/logos/Logo_25blk.gif[/img][/url]
- would generate:
Conclusion
- Use and abuse
- These tags have been provided as is as a courtesy for visitors to be able to create comments with some formatting control. Abuse of this system can lead to edited comments or removal of the comments entirely. Please use these tags wisely.