Product Information - About our software

G-book installation notes

G-book should work on any web server with PHP and mySQL support. Because of changes to the way POST and GET variables work from PHP 4.1.0 onwards G-book does require you to have PHP 4.1.0 or higher. You should be able to get G-book working simply by uploading all of the files, editing the config file and running a small SQL statement.

  • Unzip the files and place them all in the same directory

  • Edit the file called config.inc.php in your favourite text editor, such as Notepad and you should see something like this

<?php
/*
###############################################################
# G-book
# - version 1.0
# - Copyright (c) 2001-2003 Dominion Web Design
# - http://www.dominion-web.com/products/g-book/
###############################################################
#
# THIS SOFTWARE IS FREEWARE
# Redistribution is permitted so long as the copyright notices
# stay intact in the code and in the XHTML output
#
###############################################################
# Notes: This is the only file you need to configure
*/

// -------- DATABASE CONFIGURATION --------
// Database host, usually localhost will work
$dbhost = "localhost";

// Database username
$user = "username";

// Database password
$password = "password";

// The name of the database, default is gbook
$db = "gbook";

// The name of the table in the database, default is gbook
$dbtable = "gbook";

// Allow HTML, this allows the users to insert certain HTML tags into their posts
// 1 - allow HTML, 0 - deny HTML
$allowHTML = 0;

// Validate to XHTML? (Note this can be buggy with complex HTML links or images that use query strings)
// 1 - Validate to XHTML, 0 - leave as entered
$validateXHTML = 1;
?>

You will probably need to make changes to this file. To make changes to any of the default settings, enter the correct setting between the two sets of "quotes" unless they are numeric.

$dbhost: This is the location to your mySQL server. You can probably leave this set to localhost.

$user: This is the username you need to access the database in which you will store your guestbook entries.

$password: This is the password associated with the username given above.

$db: The database in which you are going to store your guestbook table.

$dbtable: The table in the database defined in $db in which you will store all of your guestbook entries

$allowHTML: You can set this to 1 to allow your users to post HTML content as messages. This is restricted to only the essential tags to prevent abuse.

$validateXHTML: G-book is written to be XHTML 1.0 Transitional compliant. If you allow your users to post HTML they may post invalid or previous versions of HTML. Setting this variable to 1 attempts to correct this problem and forcing the entry to XHTML. There are known bugs with this with regards to hyperlinks or images with query strings e.g. file.php?test=1 where ?test=1 is the querystring.

  • You may also wish to edit the files header.inc.php and footer.inc.php. This contains the XHTML code that goes above and below your guestbook entries. We strongly recommend you stick to the XHTML 1.0 Transitional standard (if you decide not to you should remove the XHTML compliance notice from the footer). All font sizes and colours are controlled from the Cascading Style Sheet file, g-book.css

  • Save the changes and upload the files to your webserver. You should upload all .PHP files in ASCII format and the .JPG file in BINARY format.

  • Run the file g-book.sql either from your mySQL command line or via a program such as PHPmyAdmin. Remember to change the name of the table to whatever you wish to call it, and make sure it is the same as that you have used in the $dbdata variable in the config.inc.php file.

 

Testing your installation

Simply call index.php from the browser to test both mySQL connectivity and validity of your installation.

Future plans and enhancements

  • The ability to define your own fields
  • An online management area to edit or delete messages. At the moment you must do this directly from mySQL either via the command link or a web based mySQL management tool such as PHPmyAdmin.

 

 

 

 

 

Copyright 1997-2009 Dominion Web All rights reserved. Privacy Policy.
Customer Support Area, Forums and Community Public and Customer Download Area DW:Design - Dominion Web DesignSoftware and Applications for the iPhone and iPod Touch Windows Applications and .NET Developer Components Dominion Web - Just imagine the possibilities Web Server Applications and Scripts