Добавил:
Опубликованный материал нарушает ваши авторские права? Сообщите нам.
Вуз: Предмет: Файл:
Building Forums With vBulletin (2006).pdf
Скачиваний:
40
Добавлен:
17.08.2013
Размер:
6.3 Mб
Скачать

Chapter 3

Private Messages

Communication is the cornerstone of a good discussion board. One facility that vBulletin offers is the ability to send a message to another user without that message appearing on the board. There are a number of easy ways to send a private message (also known as a PM) in vBulletin. (We're not going to list them all here.) One of the easiest is the following:

Click on UserCP in the navbar.

Click on Send New Message in the Private Messages section of the left-hand menu.

This brings up the Send New Private Message page.

Fill in the form.

Click Submit Message.

This form is similar to the form used to create new threads and new posts or replies. The main components of the form are:

Recipient Username(s)—This is where you enter the username of the recipient (or recipients—by default a user can send one message to as many as 5 users simultaneously). Make sure that the username is typed in correctly. Entering an incorrect username can mean that the message is not delivered or delivered to someone else! (An error message is generated if you enter a username that doesn't exist.)

Title—Here you enter the title of the message. This is similar to the subject line on an email.

Message—This is for the main body of the message.

Filling in all three of these is mandatory.

BB Code

BB Code is short for Bulletin Board Code. BB Code is a safe alternative to allowing users to use HTML to format their messages.

So, what is BB Code? BB Code is a set of codes that users can place in their posts. These codes are translated by the board when the post is submitted so that they are substituted with pre-approved HTML code.

55

A Tour of vBulletin

Why HTML is dangerous

A long time ago it was decided that allowing everyone the ability to post HTML into a web forum was a really bad idea.

Think about it. Your discussion board is controlled by a combination of HTML, PHP and MySQL queries. Giving others the ability to place code into a post could allow them to do all sorts of things. Now, most people would probably do no worse than format their posts using weird color and font schemes, making them difficult to read. However, you want a lot of people to come to your board, and eventually (the Web being what it is) there would be someone who would think it was a great idea to use HTML, PHP, or script to cause damage to the board. And believe it, they could!

vBulletin does allow you the option of activating HTML on the discussion board, but this is not recommended!

What Does BB Code Look Like?

If you've formatted a message for posting onto a vBulletin board, then you will have seen BB Code in action.

Take a look at this short section of text formatted with BB Code:

[B]Bold[/B] text goes here. This is [I]italics[/I]. This is [U]underlined[/U]. [LEFT]Left aligned.[/LEFT] [CENTER]Centered.[/CENTER]

[RIGHT]Right aligned.[/RIGHT] [INDENT]Indented![/INDENT] [list=a]

[*]Bullet - text [/list] [list=1] [*]Bullet - numbered [/list]

56

Chapter 3

This text looks like this when it is submitted for posting:

BB Code looks a lot like HTML—there are opening tags and closing tags around text. However, one key difference is that the tags have square brackets as opposed to the angled brackets in HTML. For example:

In BB Code, the opening and closing tags for bold are [B] and [/B].

In HTML, the opening and closing tags for bold are <B> and </B>.

Using BB Code

Using BB Code (especially the in-built codes) is easy because most of the commonly required codes are available from the toolbar in the message posting interface.

The AdminCP allows the administrator to add new codes to the forum. However, care is needed to ensure that these don't cause security problems.

User Tools

The user has a set of tools at their disposal:

Thread Tools—These allow the user to work with the thread.

57

A Tour of vBulletin

Search this Thread—This tool allows the user to search the current thread for keywords.

Rate Thread—This allows the user to rate the thread by giving it a rating from 5-star (excellent) to 1-star (terrible).

Display Mode—This allows the user to change the way they view a thread.

Display Modes

There are four possible display modes:

Linear mode (oldest first)—In this mode, the posts are displayed chronologically from oldest to newest. Posts are shown in what is known as flat mode so that many posts can be viewed at the same time.

58

Chapter 3

Linear mode (newest first)—This is the same as linear mode, except that posts are in the opposite order.

Threaded mode—In this mode, a tree view is shown along with every post in a thread. This view allows the reader to see the relationship between the posts, in terms of who responded to which post. In this display mode, only one post is shown at a time.

Hybrid mode—This mode is a mixture of the linear and threaded modes. The post tree is displayed as in the threaded mode, but multiple posts are displayed simultaneously as in the linear modes.

59