Readme file for NoticeBoardPro 1.0
Date: 19 April 2011
Author: John Dixon
Email: support@noticeboardpro.com
Website: www.NoticeBoardPro.com

Introduction
============

NoticeBoardPro is an online notice board written in PHP and MySQL. The software is distributed under the terms of the GNU GENERAL PUBLIC LICENSE, a copy of which is available in the gpl.txt file included in the same directory (folder) as this readme file. 

Very simply, this means that you are free to modify, distribute and re-sell the software if you want to, providing you pass the same rights on to the people to whom you supply the software.


Installing NoticeBoardPro
=========================

As NoticeBoardPro is written in PHP and MySQL, it needs to be installed on a web server that supports these technologies. You can either upload and run NoticeBoardPro on a web server that is maintained by someone else, or you can install NoticeBoard on a web server running locally on your own computer.

If you want to run NoticeBoardPro on your own computer, you can download software to enable you to set up a WAMP (Windows, Apache, MySQL, PHP/Perl) environment from several places on the web, for example, www.en.wampserver.com and www.easyphp.org. It must be stressed though that for security reasons a WAMP environment is normally used as a development environment rather than a production one.

To install NoticeBoard:

1. Using a text editor, for example, NotePad, open the file db.php. The contents of the file are repeated here for convenience:

<?php

# Name			: db.php
# Description		: Include file storing the database connection information.
# Author		: JPD
# Created		: 24 Feb 2011
# Updated		:

# MySQL Server Connection Constants. These can be changed here if the database is moved.

$hostName 		= "enter hostname here";		// Address of the database server
$databaseName 		= "enter database name here";		// Name of the database
$dbusername 		= "enter username here";		// User name
$dbpassword		= "enter password here";		// Password

# Example settings
# $hostName 		= "localhost";		// Address of the database server
# $databaseName 	= "notice_board_pro";	// Name of the database
# $dbusername 		= "root";		// User name
# $dbpassword		= "pwd1234";		// Password

?>

The four lines that need to be changed are:

$hostName 		= "enter hostname here";		// Address of the database server
$databaseName 		= "enter database name here";		// Name of the database
$dbusername 		= "enter username here";		// User name
$dbpassword		= "enter password here";		// Password

If you have set up a WAMP environment yourself, you should know what these settings need to be. If you are planning to install NoticeBoard on a web server maintained by someone else, ask them what the settings should be.

2. When you have updated the settings, save db.php (do not change the name).

3. Upload/copy all the files (except create_db_and_tables_nbp.sql) from the NoticeBoardPro folder (including the sub-folders and their contents) to the location on the web server where web pages have to be located. The name of this location will normally be called something like 'www' or 'public'. You should create a new folder in this location for all the Notice Board files. Note that although the 'photos' folder is empty, you will need this folder if you intend to allow users to upload JPEG images into NoticeBoardPro.

4. Run the script 'create_db_and_tables.sql' to create the database and tables, and populate the tables. This needs to be done on the web server where NoticeBoardPro will be running. If you have not called your database 'notice_board_pro' (see step 1, above), you will need to change both occurrences of notice_board_pro (in create_db_and_tables.sql) to the correct name of your database. 

If you are using an existing database, rather than creating a new one, you must remove from 'create_db_and_tables.sql' the line that reads:

create database notice_board_pro;

The way in which you run this script will depend on where the web server is located. It may well be that you have a program such as phpMyAdmin available to you, or you might need to run the script from within a DOS window (for a WAMP environment).


Running NoticeBoardPro
======================

1. Start the wamp server (if necessary).

2. Using a web browser, browse to the file called 'index.php', which is the NoticeBoardPro home page.

3. Register yourself as a NoticeBoardPro user and start adding items.


Browser Usage
=============

NoticeBoardPro has been tested on the following browsers:

Internet Explorer
Firefox
Chrome
Opera
Safari

The best results are obtained with Internet Explorer, Chrome and Safari, then Firefox, and finally Opera. It runs perfectly well on all browsers, it's just that the layout of a few items is a bit wonky with Firefox and Opera. 


Troubleshooting
===============


Web server
----------

If you get loads of error messages when you try to use NoticeBoardPro, check that your wamp server is running.


php.ini
-------

In most situations, the php.ini file (which is probably located in the 'apache' directory for a local installation) will be already configured to be able to handle NoticeBoardPro. However, we have found that from time to time, a couple of settings need to be amended. 

If you have access to the php.ini file, ensure that the following configuration parameters are set accordingly.</p>

Language Options

In Language Options, change:

short_open_tag = Off

to:

short_open_tag = On


Error handling and logging

Error handling and logging should be set to:

error_reporting = E_ALL & ~E_NOTICE


root user
---------

When you initially install a wamp server, the 'root' user does not have a password setup. What this means is that you could in fact set up the db.php file like this, for example:

$hostName 		= "localhost";		// Address of the database server
$databaseName 		= "notice_board_pro";	// Name of the database
$dbusername 		= "root";		// User name
$dbpassword		= "";			// Password

Here, the password is empty - it just has two double quotes right next to each.

Then, from a command prompt and in the c:\wamp\bin\mysql\mysql5.5.8\bin directory, for example, you could type

mysql -u root < create_db_and_tables_nbp.sql;

(The create_db_and_tables_nbp.sql file must already have been copied into the c:\wamp\bin\mysql\mysql5.5.8\bin folder from Windows Explorer)

Here, you're not prompted for a password.

A better solution would be to set up a password for the root user. To do this:

1. Open a command window and go to: c:\wamp\bin\mysql\mysql5.5.8\bin (for example)

2. Enter 

mysql

or

mysql -u root

This should access mysql.

3. Enter the following command, substituting your own password (the one you are using in db.php).

set password for root@localhost=password('your_password_here');

4. Exit from mysql (type exit; and press enter)

5. Enter

mysql -u root -p < create_db_and_tables_nbp.sql

(The create_db_and_tables_nbp.sql file must already have been copied into the c:\wamp\bin\mysql\mysql5.5.8\bin folder from Windows Explorer)

6. Enter your password.

This should access mysql.

7. To check that everything has been set up correctly, enter:

use notice_board_pro;

then

show tables;

All of the database tables should be listed.

Remember also that the wamp server needs to be running before you can do any of the above or before you can use NoticeBoardPro.


Help and Assistance
===================

If you are having problems installing or using NoticeBoardPro, please contact support@noticeboardpro.com.
