In the series I started on bbPress powered forums posts formatting, let's continue with the different tags used for that, as I said previously, most of those tags are basic HTML tags, used in all the web pages across the Internet.
First let's see the em tag, em is short for emphasis & this tag is used to make the text italic, same as the [I] tag we saw with bbCode.
The use of the em tag is simple, it has a starting part "<em>" & an ending part "</em>" (notice the forward slash "/" in the second part), both used to wrap the text we want to make italic. (we'll see an example below).
Another tag is the strong tag, this one makes the text wrapped strong or bold, it's like the [B] tag in bbCode. Same as the em tag & most of other HTML & bbCode tags, the strong tag has an opening part "<strong>" & an ending part "</strong>" to wrap the text.
Examples:
<em>This text is italic</em> & <strong>this is bold</strong>.
Will look like this in your formatted message:
This text is italic & this is bold.
You can combine the two tags to get your text italic AND bold:
<strong><em>This text is italic & bold</em></strong>.
Notice how I closed last the tag I opened first, that's very important.
Result:
This text is italic & bold.
Showing posts with label style-n-weight. Show all posts
Showing posts with label style-n-weight. Show all posts
Tuesday, November 20, 2007
Sunday, September 16, 2007
Posts Formatting: Bold, Italic, Underline - bbCode Basics
The most basic & most used text formatting on forum are probably Bold & Italic styles, Underline is less used but it's similar to the two others, that's why I included it in this lesson.
All three are pretty simple to use, let's have a look at the, if you read the Intro, I said this:
The codes that interest us are B for Bold, I for Italic & U for Underline, the tags then are:
[B] - Bold
[I] - Italic
[U] - Underline
let's see another part of bbCode intro
So, if you want to format a word, phrase, paragraph or a whole article, just wrap it with the desired tag:
[B]Bold[/B] will look: Bold
[I]Italic[/I] will look: Italic
[U]Underline[/U] will look: Underline
Nothing simpler, & in some popular kinds of forums, most of time you don't need to type the tags, only to select your text, click on a button & it's wrapped automatically.
Now a last thing, if you want to add more than one style to your text, simply add more tags, but remember always the tag you open first should be closed last (as explained in detail HERE), you would some times get some unpredictable results ... examples:
Wrong: [B][I]Your Text[/B][/I]
Right: [B][I]Your Text[/I][/B]
All three are pretty simple to use, let's have a look at the, if you read the Intro, I said this:
bbCode is composed of a number of tags, are composed of square brackets [...] & a code inside (instead of dots) that makes any tag different from others.
The codes that interest us are B for Bold, I for Italic & U for Underline, the tags then are:
[B] - Bold
[I] - Italic
[U] - Underline
let's see another part of bbCode intro
The tags have to wrap your content in order format it, that's why a tag is always inserted twice: in the beginning then in the end of the text you need to format, with a little difference, the tag in the end have to include the character "/" (forward slash)[...]Your Content[/...]
So, if you want to format a word, phrase, paragraph or a whole article, just wrap it with the desired tag:
[B]Bold[/B] will look: Bold
[I]Italic[/I] will look: Italic
[U]Underline[/U] will look: Underline
Nothing simpler, & in some popular kinds of forums, most of time you don't need to type the tags, only to select your text, click on a button & it's wrapped automatically.
Now a last thing, if you want to add more than one style to your text, simply add more tags, but remember always the tag you open first should be closed last (as explained in detail HERE), you would some times get some unpredictable results ... examples:
Wrong: [B][I]Your Text[/B][/I]
Right: [B][I]Your Text[/I][/B]
Subscribe to:
Posts (Atom)