Thursday, February 12, 2015

[Quick Tips]: Creating and Setting Up Your Own Forum Using phpBB

Creating and Setting Up Your Own Forum Using phpBB


phpbb

Introduction

phpBB is one of the most widely used free discussion board scripts. This free and very powerful application is easy to install and administer. It allows flexibility in terms of design and organization.
phpBB is a free flat-forum bulletin board software solution that can be used to stay in touch with a group of people or can power your entire website. You can create a very unique forum in minutes using the extensive database of user-created modifications and styles database containing hundreds of style and image packages.
phpBB is open source, licensed under Version 2 of the GNU GPL. True to its name, phpBB was written in the PHP programming language. phpBB 3.1 has the added benefit of being built upon the Symfony framework.
The objective of this article is to provide you with an understanding of installation and configuration of phpBB.

Features

  • Password Protected Forums
  • Mange Bookmarks & Subscriptions
  • Custom Profile Fields
  • Type-aware Parameter Handling and Database Layer
  • Posts/Reports Moderation Queue
  • Global Topics/Announcements
  • Manage Bans and Warnings
  • Group-based Memberlist Display
  • Multiple Attachments
  • and many.

Install phpBB on Ubuntu 14.10

System Requirements

phpBB requires certain technical requirements to be met for the store to operate properly. You should check to see that these server requirements are provided and installed on your web servers.
A webserver or web hosting account running on any major Operating System with support for PHP
A SQL database system, one of:
  • MySQL 3.23 or above (MySQLi supported)
  • MariaDB 5.1 or above
  • MS SQL Server 2000 or above (via ODBC)
  • MS SQL Server 2005 or above (via the native adapter, SQLSRV)
  • Oracle
  • PostgreSQL 8.3+
  • SQLite 2
  • SQLite 3
PHP 5.3.3+ (>=5.3.3, >6.0-dev (compatible)) with support for the database you intend to use.
  • getimagesize() function enabled
The following PHP modules are required.
  • json
The following PHP modules are optional, but will provide access to additional features
  • zlib Compression support
  • Remote FTP support

Step 1: Install Prerequisites

Here, we will use Apache web server with phpBB. Before get started install phpBB, you need to install a web server on Ubuntu (Apache, PHP, MySQL) called LAMP server, open terminal then running following commands:
sudo apt-get install lamp-server^
You may need to install some php5 libraries and unzip which handles .zip files on your VPS. You can install these libraries by running this simple command:
sudo apt-get install php5-gd imagemagick unzip

Step 2: Creating A MySQL Database & User

The next step is to create a database on the MySQL server for phpbbdb to store a shop’s data on.
Open the terminal and run this command to log in to MySQL server (use the MySQL password you have entered during the installation of the LAMP Server):
mysql -u root -p
Create a database for phpBB.
create database phpbbdb;
Create MySQL user administrator of phpbbdb.
create user adminphpbb;
Now Give user: admim123 a password
set password for 'phpbbdb' = password('admin123');
We will use this database information later when we are configuring OpenCart using the auto-installer.
Set  privileges adminphpbb to access database phpbbdb using this command:
grant all privileges on phpbbdbdb.* to adminphpbbdb@localhost
Now, Exit from MySQL server,by typing command:
FLUSH PRIVILEGES;
exit

Step 3: Downloading and unzipping phpBB archive

The latest version of phpBB is 3.1.3, released on 2015-02-01 can be downloaded from the phpBB website.
To download open the terminal and type in the following command:
wget https://www.phpbb.com/files/release/phpBB-3.1.3.zip
Now we will unzip this downloaded phpBB zip file in the current directory:
unzip phpBB-3.1.3.zip
We have to move the files & folders present in uploads folder into the root www folder.
sudo cp -R phpBB3/* /var/www/html/
You can now find all the core files & folders of phpBB directly sitting in your root www folder.
Move to the /var/www/html/ directory.
cd /var/www/html/
We will give the ownership of our phpBB files to the apache user by running the following command:
sudo chown www-data:www-data * -R
Add permissions for the group to the following directories and files.
sudo chmod 660 images/avatars/upload/ config.php
sudo chmod 770 store/ cache/ files/

Step 4: Web installation

With a new database freshly created, we are now ready to install phpBB directly onto a website. You should open up a web browser and enter in the web address of where they uploaded phpBB. You should be automatically greeted by the following page:
After checking the terms and conditions,  you should click on the Install tab.
You should have all the required packages already installed. Click Proceed to next step, then Start install.
The next page is Installation compatibility. The Start Install button is available at the bottom of the page.
Enter the database credentials, replacing the database name, username, and password with your own values.If you have correctly entered the database details you should see a successful database connection.
In this next step, you should set up your administrator username and password.
A confirmation that the user administrator was successfully created and  you should click on the Proceed to next step button. This will bring you to the  successful installation confirmation page.
Once you have installed phpBB, it is good practice and necessary from a security point of view to delete your install folder. We should be careful that only the install folder is to be deleted and not others folders. You can use the following command.
rm -rf /var/www/install/
and remove some permissions on the config.php file.
sudo chmod 640 /var/www/html/config.php
Now you can access your phpBB forum at your Droplet’s IP address http://your_server_ip/.
ca
Now that you have installed phpBB, you have a free alternative that will allow to build a successful online forum on your website.
The administrator of a board has many powers, including fine-tuning the board settings and managing users. You can find out more about administrators in the phpBB Administration Guide.
Enjoy!

No comments: