Location: PHPKode > projects > Easy to use shoutbox > README.txt

You just can't wait to hear people's shouts? Ok, let's go!

Just copy the text of create_db.sql and paste it into a query-section in phpMyAdmin. You can set it up with the native mysql-client either, but then I guess you know what you have to do. The database must be created before you run the script! Otherwise you will get a connection-error.

Then you may want to set up the script. Though it's not neccessary, I recommend just to take a look at the first few lines. It won't take much time and you can make it fit your needs. I hope the parameters are self-describing enough for you, for further information just look at the "Scriptparameter"-section in this document.

For a last step, paste the script onto your server and be happy watching your shout-archive grow =).

2. Scriptparameters

$include_script (0 or 1)
Tells the script if it is included into an existing webappearance (1) or if it is run exclusively (0). If you link this document, a new XHTML-construct will be build around the script. Surely it is conform with the XHTML 1 standards of the w3c.

$count_shouts (0 to infinite)
Count of shouts that are shown. It simply limits the rows that are returned by the database-query.

$default_message (string)
This is the default message that is shown in the formular underneath the shouts. Can be set to '' if you don't wish this.

$layout_class (string)
If you already have a web-appearance and want to extend it with the shoutbox, just tell it, what class the table-, tr- and td-elements shall be. Your CSS has to cover the scheme e.g. "table.<your layout-class>". Further you have to include the script (see $include_script), to be able to use your own CSS-file which is given in your HTML-document.

$dbname (string)
The database-name to get the shouts from. Only alter it if you altered the create_db script!

$dbuser (string)
The user who connects to the database. I prefer not to work with root-priviliges, so I created the user "shoutmaster" on your db (blame me ;-)), which has only full access to the database you use fot the shouts. Only alter it if you altered the create_db script!

$dbpasswd (string)
Clear password for the $dbuser. The script will encrypt it to md5-hash when the script is run. I STRONGLY recommend to change it as soon as possible on the database as in the script. Everyone knowing this schoutbox can hack your shout-db! But nothing else =).

$dbhost (string)
The host which contains mysql-services and your database. 'localhost' will fit for 99% of users.

$length_shout (integer)
This sets the character-count for the shout input-field. Though there are more characters allowed in your database!

$blacklist (commaseperated string)
Commaseperated list of words to blacken. For your information: I am a strong enemy of censorship, so the 'raw and nasty' shouts will be saved in the database. If you deceide not to filter anything later, fine! Although I don't encourage you to do so, just set $blacklist to '' and every single word will be shown! Otherwise it will be set to blacklist-chars like '*'.

Return current item: Easy to use shoutbox