Installation Instructions 1. Unpack phpgiftreg website 2. Create MySQL database 3. Create MySQL tables 4. Create MySQL user (optional) 5. Configure db.php 6. Configure config.php (optional) 7. Create Apache alias ============================================================================= 1. Unpack phpgiftreg website Change to the directory where you're going to run the website from and extract the pages. The tarball contains the phpgiftreg/ directory itself. user@host $ tar -xvzf phpgiftreg-x.x.x.tar.gz Then give everything the proper permissions (thanks to Paul Hubbard for pointing this out). An example would be owner-writable, world-readable: user@host $ cd phpgiftreg-x.x.x user@host $ chmod 644 *.php *.css images/* ============================================================================= 2. Create MySQL database Login to the MySQL server with a user capable of creating databases. If you're running a trusted system, simply executing `mysql' should be adequate. Otherwise, do something like this: user@host $ mysql -u username -h host -p Enter password: Welcome to the MySQL monitor. Commands end with ; or \g. Your MySQL connection id is 626 to server version: 3.23.58-log Type 'help;' or '\h' for help. Type '\c' to clear the buffer. mysql> Once inside, create the phpgiftreg database: mysql> create database phpgiftreg; Database phpgiftreg created. ============================================================================= 3. Create MySQL tables Edit create-phphgiftregdb.sql and scan to the bottom where rows are inserted into the `users' table. Change the INSERT statement and add more to create the users who can initially use the gift registry. As well, you can examine the area where the `ranks' table is populated and modify that, too. There's a column for the rank's description and how it should look when rendered in HTML. By default, it shows between 1 and 5 stars, which should be suitable for most installations. Change to the phpgiftreg database like this: mysql> use phpgiftreg; Reading table information for completion of table and column names You can turn off this feature to get a quicker startup with -A Database changed Run the create-phpgiftregdb.sql script like this: mysql> source /path/to/create-phpgiftregdb.sql mysql> ============================================================================= 4. Create MySQL user (optional) You should have a separate user for the database. If you choose to, create the new user like so: mysql> GRANT ALL ON phpgiftreg.* TO username@host IDENTIFIED BY 'password'; mysql> FLUSH PRIVILEGES; This creates a user called `username' that can connect from `host'. ============================================================================= 5. Configure db.php Change to the phpgiftreg/ directory and edit the db.php file. There's a line with a call to mysql_connect(). Change it to suit your setup. mysql_connect("host","username","password") or die("Could not connect: " . mysql_error()); ============================================================================= 6. Configure config.php There are some options to change in config.php if you wish. Their functions are described in that file. ============================================================================= 7. Create Apache alias Edit your httpd.conf and add an Alias like so: Alias /phpgiftreg/ "/path/to/phpgiftreg/" The trailing slashes are important. Restart the web server and you should be good to go. ============================================================================= If you have any problems with these instructions, or if they weren't clear or just didn't plain work, please let me know at generalpf@yahoo.com.