- •Table of Contents
- •Preface
- •What This Book Covers
- •Conventions
- •Reader Feedback
- •Customer Support
- •Downloading the Example Code for the Book
- •Errata
- •Questions
- •What is vBulletin?
- •Why Have a Discussion Board?
- •Benefits of a Discussion Board
- •Why vBulletin?
- •History
- •Development
- •The vBulletin Advantage
- •Versatile
- •Performance
- •Customizable
- •Easy to Maintain
- •Other Features
- •vBulletin Licensing Options
- •Leased License
- •Owned License
- •Choosing a License
- •Example vBulletin Sites
- •Summary
- •Requirements
- •Disk Space
- •Bandwidth
- •System Resources
- •Shared Hosting
- •Semi-Dedicated Hosting
- •Dedicated Hosting
- •Other Options
- •Installing vBulletin
- •Tools
- •Downloading the Installation Files
- •File Extraction
- •Upload Preparation
- •Creating the Database
- •Command-Line Database Creation
- •cPanel Database Creation
- •File Editing
- •Uploading the vBulletin Files
- •Running the vBulletin Installation Script
- •Troubleshooting
- •Database Access Issues
- •Images/Styling Not Showing
- •PHP Errors
- •The vBulletin Control Panel
- •Importing Data into vBulletin
- •Downloading the ImpEx Script
- •Compatibility
- •Preparing for Upload
- •Editing the Configuration File
- •Upload the ImpEx Script
- •Running the ImpEx Script
- •Default Usergroups
- •Securing vBulletin
- •Help & Support
- •Summary
- •The vBulletin User Experience
- •How to Get to the Board?
- •What the End Users See
- •Site Logo
- •Forum Title, Login Box, and Navbar
- •Welcome Banner
- •Main Body of the Forum
- •What's Going On
- •Footer
- •Touring the Main Forum—Unregistered Users
- •No "New Threads" for Unregistered Users
- •Registering on a vBulletin Board
- •Touring the Forum—Members
- •New Threads
- •Replying
- •Editing a Message
- •Private Messages
- •BB Code
- •User Tools
- •Display Modes
- •Navbar Changes for Members
- •The vBulletin Administrator Experience
- •Forum and Thread Tools
- •The AdminCP
- •Control Panel Home
- •Latest Version Information
- •vBulletin Options
- •Forum Management
- •Editing and Adding Forums
- •Editing Existing Forums
- •Moderation Options
- •Forum Styling
- •Access Control Options
- •Forum Posting Options
- •Enable/Disable Features
- •Branding
- •Changing the Logo
- •Undoing the Change
- •Summary
- •Types of Customization
- •CSS Modifications
- •Changing the Table Title Text
- •Viewing Changes
- •Undoing the Changes
- •Phrase Modifications
- •Searching for Phrases
- •Making Changes
- •Viewing the Changes
- •Undoing Changes
- •Template Modifications
- •Accessing Templates
- •Exploring a Template
- •Template Structure
- •Adding a FORUMHOME Sidebar
- •Two Changes
- •PHP Code Modifications
- •PayPal Modification
- •File Modification
- •Hacks
- •Pros and Cons of Hacking a vBulletin Board
- •Finding a Hack
- •Installing a Hack
- •Backing Up a Hack
- •Commercial Hacks
- •Summary
- •Setting Up a Forum
- •Creating the Forum
- •Forum Permissions
- •Viewing Permissions
- •Opening the Forum
- •Super Administrators
- •Creating a Super Administrator
- •Other Changes to the config.php File
- •Admin Log Viewing Permission
- •Admin Log Pruning Permission
- •Query Running Permission
- •Undeletable and Unalterable Users
- •Maintaining the Database
- •Backing Up the Database
- •Repairing and Optimizing the Database
- •Some Maintenance Issues
- •Smilies
- •Editing a Smilie
- •Adding a New Smilie
- •Uploading a Smilie
- •Creating Your Own Smilies
- •Avatars
- •Adding Avatars
- •Storing Avatars
- •Summary
- •When to Upgrade
- •Preparing for Upgrade
- •Migrating Changes
- •File Compare Utilities
- •Uploading the Files
- •Running the Upgrade Script
- •Testing the Upgrade
- •Unveiling the Upgrade
- •Summary
- •Styling vBulletin
- •Template Lifecycles
- •Lifecycle 1—Constant Change
- •Lifecycle 2—Working Behind the Scenes
- •Editing the Default Style
- •Changing Image Paths
- •Other Editable Elements
- •Some Tips about Editing Styles
- •Adding a New Style
- •Editing the Style
- •Saving the Style
- •Downloading the Style
- •Making the New Style into the Default
- •Distributing a Style
- •Installing a New Style
- •Summary
- •Hacking vBulletin
- •Making the Changes
- •Locating the Template
- •Hacking the pm_newpm Template
- •Testing the Hack
- •Hack Distribution
- •Tips for Hack Distribution
- •Plugins and Products
- •Getting Plugins and Products
- •Adding a Product
- •Adding a Plugin
- •What If Things Go Wrong?
- •Summary
- •Default Usergroup Settings
- •(COPPA) Users Awaiting Moderation
- •Administrators
- •Moderators
- •Registered Users
- •Super Moderators
- •Unregistered / Not Logged In
- •Users Awaiting Email Confirmation
- •Banned Users
- •Default vBulletin Database Tables
- •Moving Servers in Six Easy Steps
- •Cookie Check
- •Back up Database
- •Download the vBulletin Files
- •Transfer to New Server
- •Database Restoration
- •Back Online
- •Graphics
- •Global Post Text Find and Replace
- •Programming Standards
- •Braces
- •Indenting
- •Give Operators Space
- •String Quoting
- •Return Values
- •SQL Queries
- •Naming Conventions for Functions
- •Summary
- •vBulletin Directory Structure
- •Notes
- •Official vBulletin Sites
- •Main vBulletin Hack Site
- •vBulletin Styles and Templates
- •vBulletin Add-Ons
- •Index
Chapter 4
Recovering phrases
If you didn't keep a backup of the phrases that you changed, all is not lost. They are all stored in the file \install\vbulletin-language.xml. If you search this file, you'll find all the phrases that vBulletin uses.
Template Modifications
So far we've looked at how to modify CSS stylesheet information, which controls how vBulletin looks, and the phrases, which control the text. Both of these modifications allow you to radically change how your vBulletin board looks and feels. Template modifications allow you to do a lot more and to make much more radical changes to your vBulletin installation. In fact, templates control nearly every aspect of a vBulletin board. Each page that the end user sees is the result of one or more templates coming together and displaying information.
Let's take a closer look at templates in vBulletin.
Templates are powerful yet complicated
Just a note about templates though, before we go further. Templates are quite complicated, and you need a good knowledge of how HTML works to make small changes. To make bigger changes you need to have an understanding of how the templates work. Work methodically and make notes of the changes you make. That way, if something goes wrong, you can undo it. If things go drastically wrong, you can always reverse all the changes made.
Accessing Templates
To access the templates, first click on Styles & Templates in the left-hand navigation pane to expand the menu. From there, click on Style Manager as shown below.
It's the next stage that many people find confusing—finding the templates! The way to get the right-hand frame to display the templates is to click on the 'expand templates' button on the right of the screen. It looks like << >> (shown below).
This now displays some of the templates used by vBulletin, some of which are shown below. Most of the pages that you see when using a vBulletin board are made up of one or more of these templates. (Generally, a page is made of three: a header, a footer, and the main body.)
99
Customizing Your vBulletin Board
Here, templates are grouped. Headings are in blue, and template names are in white. As you will see later, edited templates appear in red text to make finding them easier.
To display all the templates, you have to click on another button, again marked << >>, to expand all the template groups.
100
Chapter 4
You will now see a full listing of the vBulletin templates available. There are a significant number, and they are grouped into 34 categories:
•BB Code Layout Templates
•Buddy List Templates
•Calendar Templates
•Editor Templates
•FAQ Templates
•Forum Display Templates
•Forum Home Templates
•Help Templates
•Instant Messaging Templates
•Member Info Templates
•Modify User Option Templates
•Navigation / Breadcrumb Templates
•New Posting Templates
•Page Navigation Templates
•PHP Include Code Templates
•Private Message Templates
•Poll Templates
•Postbit Templates
•Post Icon Templates
•Printable Thread Templates
•Registration Templates
•User Reputation Templates
•Search Templates
•Show Groups Templates
•Show Thread Templates
•Smilie Popup Templates
•Subscribed Thread Templates
•Paid Subscriptions Templates
•Thread Administration Templates
•User Control Panel Templates
•User Profile Field Templates
•User Note Templates
•Who Posted? Templates
•Who's Online Templates
101
Customizing Your vBulletin Board
Exploring a Template
Let's take a close-up look at a template. We're going to examine the FORUMHOME template, which is the main template that controls the look and operation of the forum homepage. To find this template, scroll down the Forum Home Templates section and double-click on FORUMHOME to open it. The template opens in vBulletin's template editor as shown below:
In-built template editing
By now you're probably noticing how little you have to use any external editors when working with vBulletin—most features can be edited through vBulletin's own editing interface. This saves the administrator a lot of time and effort, as well as reducing the time it take to make changes—the changes are done directly to the data on the server, and no FTP program is required!
You might not believe it, but the code shown is the code that underlies the main vBulletin forum page that you see when viewing the forum.
102
