<?PHP
/* ====================
[BEGIN_SED]
File=plugins/guestbook/guestbook.setup.php
Version=100
Updated=16/12/2009
Type=Plugin
Author=riptide (Admin answer by Слай)
Description=Setup for the guestbook
[END_SED]

[BEGIN_SED_EXTPLUGIN]
Code=guestbook
Name=Guestbook
Description=Guestbook
Version=cot-1.0
Date=16/12/2009
Author=riptide (Admin answer by Слай)
Copyright=This plugin can be used for free.<br />The icons on the buttons are licensed under <a href="http://creativecommons.org/licenses/by/2.5/">Creative Commons Attribution 2.5 license</a>.
Notes=Requires CAPTCHA Manager plugin and some CAPTCHA implementation
SQL=
Auth_guests=R
Lock_guests=12345A
Auth_members=RW
Lock_members=12345A
[END_SED_EXTPLUGIN]

[BEGIN_SED_EXTPLUGIN_CONFIG]
maxposts=01:string::10:Max posts per page
authorlink=10:select:Yes,No:Yes:Display author as link to user details
verify=11:select:Yes,No:Yes:Guest must verify with a CAPTCHA to prevent spam
minchars=12:string::2:Min chars per post
maxchars=02:string::1000:Max chars per post
formatdate=04:string::d.m.Y:Dateformat
formattime=05:string::H&#58;i:Timeformat
multiposting=06:select:Yes,No:Yes:Allow multiposting
editable=07:select:Yes,No:Yes:Allow registered members to edit their own entry
bbcodes=08:select:Yes,No:Yes:Allow bbcodes
smilies=09:select:Yes,No:Yes:Allow smilies
[END_SED_EXTPLUGIN_CONFIG]
==================== */

if ( !defined('SED_CODE') ) { die("Wrong URL."); }

if ($action == 'install')
{
	sed_sql_query("CREATE TABLE `sed_guestbook` (
`gb_id` INT( 11 ) NOT NULL AUTO_INCREMENT ,
`gb_answer` TEXT NOT NULL ,
`gb_author` VARCHAR( 24 ) NOT NULL ,
`gb_authorid` INT( 11 ) ,
`gb_text` TEXT NOT NULL ,
`gb_date` INT( 11 ) NOT NULL ,
`gb_email` VARCHAR( 64 ) NOT NULL ,
`gb_website` VARCHAR( 128 ) NOT NULL ,
PRIMARY KEY ( `gb_id` )
) DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci");
}
elseif ($action == 'uninstall')
{
	sed_sql_query("DROP TABLE `sed_guestbook");
}
?>
