//////////////////////////////////////////////////////////////
//===========================================================
//===========================================================
// AEF : Advanced Electron Forum
// Inspired by Pulkit and taken over by Electron
// ----------------------------------------------------------
// Started by: Electron, Ronak Gupta, Pulkit Gupta
// Site: http://www.anelectron.com/ (Anelectron)
// ----------------------------------------------------------
// Please Read the Terms of use at http://www.anelectron.com
// ----------------------------------------------------------
//===========================================================
//===========================================================
//////////////////////////////////////////////////////////////
if(!empty($__settings['utf8'])){
$queries[] = "ALTER DATABASE ".$__settings['softdb']."
DEFAULT CHARACTER SET utf8
DEFAULT COLLATE utf8_general_ci";
$queries[] = "CREATE TABLE ".$__settings['dbprefix']."apps (
`apid` mediumint(8) NOT NULL auto_increment,
`ap_name` varchar(100) NOT NULL default '',
`ap_version` varchar(15) NOT NULL default '',
`installed_time` int(10) NOT NULL default '0',
`ap_info` varchar(255) NOT NULL default '',
) TYPE=MyISAM".(empty($__settings['utf8']) ? '' : " DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci");
//Apps Registry - Applications Registry
$queries[] = "CREATE TABLE ".$__settings['dbprefix']."apps_registry (
`apid` mediumint(8) NOT NULL default '0',
`uid` mediumint(8) NOT NULL default '0',
`apps_registry` text NOT NULL,
UNIQUE KEY `apid` (`apid`,`uid`)
) TYPE=MyISAM".(empty($__settings['utf8']) ? '' : " DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci");
$queries[] = "CREATE TABLE ".$__settings['dbprefix']."attachment_mimetypes (
atmtid smallint(5) NOT NULL auto_increment,
atmt_ext varchar(20) NOT NULL default '',
atmt_mimetype varchar(255) NOT NULL default '',
atmt_icon tinytext NOT NULL,
atmt_posts tinyint(2) NOT NULL default '0',
atmt_avatar tinyint(2) NOT NULL default '0',
atmt_isimage tinyint(2) NOT NULL default '0',
) TYPE=MyISAM".(empty($__settings['utf8']) ? '' : " DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci");
//Data for Attacment Mimetypes
$queries[] = "INSERT INTO ".$__settings['dbprefix']."attachment_mimetypes VALUES (1, 'png', 'image/png', 'png.png', 1, 1, 1)";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."attachment_mimetypes VALUES (2, 'jpg', 'image/jpeg', 'jpg.png', 1, 1, 1)";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."attachment_mimetypes VALUES (3, 'gif', 'image/gif', 'gif.png', 1, 1, 1)";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."attachment_mimetypes VALUES (4, 'bmp', 'image/bitmap', 'bmp.png', 1, 1, 1)";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."attachment_mimetypes VALUES (5, 'tiff', 'image/tiff', 'tiff.png', 1, 1, 1)";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."attachment_mimetypes VALUES (6, 'txt', 'plain/text', 'txt.png', 1, 0, 0)";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."attachment_mimetypes VALUES (7, 'jpeg', 'image/jpeg', 'jpg.png', 1, 1, 1)";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."attachment_mimetypes VALUES (8, 'doc', 'application/msword', 'doc.png', 1, 0, 0)";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."attachment_mimetypes VALUES (9, 'mpg', 'video/mpeg', 'mpg.png', 1, 0, 0)";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."attachment_mimetypes VALUES (10, 'zip', 'application/zip', 'zip.png', 1, 0, 0)";
$queries[] = "CREATE TABLE ".$__settings['dbprefix']."attachments (
atid mediumint(8) NOT NULL auto_increment,
at_original_file tinytext NOT NULL,
at_file tinytext NOT NULL,
at_mimetype_id smallint(5) NOT NULL default '0',
at_size int(10) NOT NULL default '0',
at_fid smallint(5) NOT NULL default '0',
at_pid int(10) NOT NULL default '0',
at_downloads int(10) NOT NULL default '0',
at_time int(10) NOT NULL default '0',
at_mid mediumint(8) NOT NULL default '0',
at_width smallint(5) NOT NULL default '0',
at_height smallint(5) NOT NULL default '0',
) TYPE=MyISAM".(empty($__settings['utf8']) ? '' : " DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci");
$queries[] = "CREATE TABLE ".$__settings['dbprefix']."categories (
cid smallint(5) NOT NULL auto_increment,
`order` smallint(5) NOT NULL default '0',
collapsable tinyint(2) NOT NULL default '1',
) TYPE=MyISAM".(empty($__settings['utf8']) ? '' : " DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci");
$queries[] = "INSERT INTO ".$__settings['dbprefix']."categories VALUES (1, 'General Stuff', 1, 1)";
$queries[] = "CREATE TABLE ".$__settings['dbprefix']."errors (
type tinyint(3) NOT NULL default '0',
id mediumint(5) NOT NULL default '0'
) TYPE=MyISAM".(empty($__settings['utf8']) ? '' : " DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci");
$queries[] = "CREATE TABLE ".$__settings['dbprefix']."forumpermissions (
fpfid smallint(5) NOT NULL default '0',
fpugid mediumint(5) NOT NULL default '0',
can_post_topic tinyint(2) NOT NULL default '0',
can_reply tinyint(2) NOT NULL default '0',
can_vote_polls tinyint(2) NOT NULL default '0',
can_post_polls tinyint(2) NOT NULL default '0',
can_attach tinyint(2) NOT NULL default '0',
can_view_attach tinyint(2) NOT NULL default '0',
UNIQUE KEY fpfid (fpfid,fpugid)
) TYPE=MyISAM".(empty($__settings['utf8']) ? '' : " DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci");
$queries[] = "CREATE TABLE ".$__settings['dbprefix']."forums (
`fid` smallint(5) NOT NULL auto_increment,
`cat_id` smallint(5) NOT NULL default '0',
`par_board_id` smallint(5) NOT NULL default '0',
`forum_order` smallint(5) NOT NULL default '0',
`member_group` tinytext NOT NULL,
`fname` tinytext NOT NULL,
`description` tinytext NOT NULL,
`fimage` tinytext NOT NULL,
`fredirect` tinytext NOT NULL,
`ntopic` mediumint(8) NOT NULL default '0',
`nposts` mediumint(8) NOT NULL default '0',
`status` tinyint(3) NOT NULL default '1',
`prune` tinyint(3) NOT NULL default '0',
`allow_poll` tinyint(2) NOT NULL default '0',
`allow_html` tinyint(2) NOT NULL default '0',
`id_skin` smallint(5) NOT NULL default '0',
`override_skin` tinyint(2) NOT NULL default '0',
`inc_mem_posts` tinyint(2) NOT NULL default '1',
`quick_reply` tinyint(2) NOT NULL default '0',
`f_last_pid` int(10) NOT NULL default '0',
`frulestitle` tinytext NOT NULL,
`mod_topics` tinyint(2) NOT NULL default '0',
`mod_posts` tinyint(2) NOT NULL default '0',
`rss` int(4) NOT NULL default '0',
`rss_topic` int(4) NOT NULL default '0',
) TYPE=MyISAM".(empty($__settings['utf8']) ? '' : " DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci");
$queries[] = "INSERT INTO ".$__settings['dbprefix']."forums VALUES (1, 1, 0, 1, '-1,0,2,3', 'Generals', 'Talk about anything you like in general!', '', '', 1, 1, 1, 0, 1, 1, 0, 0, 1, 0, 0, '', '', 0, 0, 10, 10)";
$queries[] = "CREATE TABLE ".$__settings['dbprefix']."fpass (
fpuid mediumint(8) NOT NULL default '0',
resetcode varchar(10) NOT NULL default '',
fptime int(10) NOT NULL default '0',
) TYPE=MyISAM".(empty($__settings['utf8']) ? '' : " DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci");
//Marked read topics and forums
$queries[] = "CREATE TABLE ".$__settings['dbprefix']."mark_read (
mr_uid mediumint(8) NOT NULL default '0',
mr_fid smallint(5) NOT NULL default '0',
mr_time int(10) NOT NULL default '0',
UNIQUE KEY mr_uid (mr_uid,mr_fid)
) TYPE=MyISAM".(empty($__settings['utf8']) ? '' : " DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci");
$queries[] = "CREATE TABLE ".$__settings['dbprefix']."moderators (
mod_mem_id mediumint(8) NOT NULL default '0',
mod_fid smallint(5) NOT NULL default '0',
UNIQUE KEY mod_mem_id (mod_mem_id,mod_fid)
) TYPE=MyISAM".(empty($__settings['utf8']) ? '' : " DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci");
$queries[] = "CREATE TABLE ".$__settings['dbprefix']."news (
`nid` mediumint(8) NOT NULL auto_increment,
`uid` mediumint(8) NOT NULL default '0',
`title` tinytext NOT NULL,
`time` int(12) NOT NULL default '0',
`image` tinytext NOT NULL,
`fullstorylink` tinytext NOT NULL,
`approved` tinyint(2) NOT NULL default '0',
`showinticker` int(10) NOT NULL default '0',
) TYPE=MyISAM".(empty($__settings['utf8']) ? '' : " DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci");
$queries[] = "CREATE TABLE ".$__settings['dbprefix']."notify_forum (
notify_mid mediumint(8) NOT NULL default '0',
notify_fid smallint(5) NOT NULL default '0',
UNIQUE KEY notify_mid (notify_mid,notify_fid)
) TYPE=MyISAM".(empty($__settings['utf8']) ? '' : " DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci");
$queries[] = "CREATE TABLE ".$__settings['dbprefix']."notify_topic (
notify_mid mediumint(8) NOT NULL default '0',
notify_tid mediumint(8) NOT NULL default '0',
UNIQUE KEY notify_mid (notify_mid,notify_tid)
) TYPE=MyISAM".(empty($__settings['utf8']) ? '' : " DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci");
$queries[] = "CREATE TABLE ".$__settings['dbprefix']."permissions (
`member_group_id` mediumint(8) NOT NULL default '0',
`view_forum` tinyint(2) NOT NULL default '0',
`can_post_topic` tinyint(2) NOT NULL default '0',
`can_reply` tinyint(2) NOT NULL default '0',
`can_edit_own_topic` tinyint(2) NOT NULL default '0',
`can_edit_other_topic` tinyint(2) NOT NULL default '0',
`can_edit_own` tinyint(2) NOT NULL default '0',
`can_edit_other` tinyint(2) NOT NULL default '0',
`approve_topics` tinyint(2) NOT NULL default '0',
`approve_posts` tinyint(2) NOT NULL default '0',
`can_del_own_post` tinyint(2) NOT NULL default '0',
`can_del_other_post` tinyint(2) NOT NULL default '0',
`can_search` tinyint(2) NOT NULL default '0',
`can_email_mem` tinyint(2) NOT NULL default '0',
`can_email_friend` tinyint(2) NOT NULL default '0',
`can_edit_own_profile` tinyint(2) NOT NULL default '0',
`can_edit_other_profile` tinyint(2) NOT NULL default '0',
`can_del_own_account` tinyint(2) NOT NULL default '0',
`can_del_other_account` tinyint(2) NOT NULL default '0',
`can_ban_user` tinyint(2) NOT NULL default '0',
`can_del_own_topic` tinyint(2) NOT NULL default '0',
`can_del_other_topic` tinyint(2) NOT NULL default '0',
`can_view_poll` tinyint(2) NOT NULL default '0',
`can_vote_polls` tinyint(2) NOT NULL default '0',
`can_post_polls` tinyint(2) NOT NULL default '0',
`can_edit_other_poll` tinyint(2) NOT NULL default '0',
`can_edit_own_poll` tinyint(2) NOT NULL default '0',
`add_poll_topic_own` tinyint(2) NOT NULL default '0',
`add_poll_topic_other` tinyint(2) NOT NULL default '0',
`can_rem_own_poll` tinyint(2) NOT NULL default '0',
`can_rem_other_poll` tinyint(2) NOT NULL default '0',
`can_merge_topics` tinyint(2) NOT NULL default '0',
`can_merge_posts` tinyint(2) NOT NULL default '0',
`can_split_topics` tinyint(2) NOT NULL default '0',
`can_email_topic` tinyint(2) NOT NULL default '0',
`can_make_sticky` tinyint(2) NOT NULL default '0',
`can_move_own_topic` tinyint(2) NOT NULL default '0',
`can_move_other_topic` tinyint(2) NOT NULL default '0',
`can_lock_own_topic` tinyint(2) NOT NULL default '0',
`can_lock_other_topic` tinyint(2) NOT NULL default '0',
`can_announce_topic` tinyint(2) NOT NULL default '0',
`can_report_post` tinyint(2) NOT NULL default '0',
`can_report_pm` tinyint(2) NOT NULL default '0',
`prefix` varchar(80) NOT NULL default '',
`suffix` varchar(80) NOT NULL default '',
`can_attach` tinyint(2) NOT NULL default '0',
`can_view_attach` tinyint(2) NOT NULL default '0',
`can_remove_attach` tinyint(2) NOT NULL default '0',
`max_attach` mediumint(8) NOT NULL default '0',
`notify_new_posts` tinyint(2) NOT NULL default '0',
`notify_new_topics` tinyint(2) NOT NULL default '0',
`use_avatar` tinyint(2) NOT NULL default '0',
`url_avatar` tinyint(2) NOT NULL default '0',
`upload_avatar` tinyint(2) NOT NULL default '0',
`hide_online` tinyint(2) NOT NULL default '0',
`view_active` tinyint(2) NOT NULL default '0',
`view_anonymous` tinyint(2) NOT NULL default '0',
`allow_html` tinyint(2) NOT NULL default '0',
`has_priviliges` tinyint(2) NOT NULL default '0',
`view_ip` tinyint(2) NOT NULL default '0',
`can_admin` tinyint(2) NOT NULL default '0',
`can_use_pm` tinyint(2) NOT NULL default '0',
`max_stored_pm` mediumint(8) NOT NULL default '0',
`max_mass_pm` mediumint(8) NOT NULL default '0',
`view_offline_board` tinyint(2) NOT NULL default '0',
`can_view_profile` tinyint(2) NOT NULL default '0',
`view_members` tinyint(2) NOT NULL default '0',
`view_stats` tinyint(2) NOT NULL default '0',
`can_submit_news` tinyint(2) NOT NULL default '0',
`can_approve_news` tinyint(2) NOT NULL default '0',
`can_edit_news` tinyint(2) NOT NULL default '0',
`can_delete_news` tinyint(2) NOT NULL default '0',
`group_message` text NOT NULL,
`can_shout` tinyint(2) NOT NULL default '0',
`can_del_shout` tinyint(2) NOT NULL default '0',
`view_calendar` tinyint(2) NOT NULL default '0',
PRIMARY KEY (`member_group_id`)
) TYPE=MyISAM".(empty($__settings['utf8']) ? '' : " DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci");
$queries[] = "INSERT INTO ".$__settings['dbprefix']."permissions VALUES (-1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, '', 0, 0, 1)";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."permissions VALUES (1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, '', '', 1, 1, 1, 50000, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, '', 1, 1, 1)";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."permissions VALUES (3, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, '', '', 1, 1, 1, 2048, 1, 1, 1, 1, 1, 1, 1, 0, 0, 1, 1, 0, 1, 150, 0, 0, 1, 1, 1, 1, 0, 0, 0, '', 1, 0, 1)";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."permissions VALUES (2, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, '', '', 1, 1, 1, 2048, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 0, 1, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, '', 1, 1, 1)";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."permissions VALUES (-3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, '', '', 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, '', 0, 0, 1)";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."permissions VALUES (0, 1, 1, 1, 1, 0, 1, 0, 0, 0, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 1, 1, 1, 0, 1, 1, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 1, 1, '', '', 1, 1, 0, 1024, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1, 200, 5, 0, 1, 1, 1, 1, 0, 0, 0, '', 1, 0, 1)";
$queries[] = "CREATE TABLE ".$__settings['dbprefix']."pm (
pmid mediumint(8) NOT NULL auto_increment,
pm_from mediumint(8) NOT NULL default '0',
pm_to mediumint(8) NOT NULL default '0',
pm_time int(10) NOT NULL default '0',
pm_read_time int(10) NOT NULL default '0',
pm_folder tinyint(2) NOT NULL default '0',
pm_subject tinytext NOT NULL,
pm_track tinyint(2) NOT NULL default '0',
pm_to_text tinytext NOT NULL,
) TYPE=MyISAM".(empty($__settings['utf8']) ? '' : " DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci");
$queries[] = "CREATE TABLE ".$__settings['dbprefix']."poll_options (
pooid mediumint(10) NOT NULL auto_increment,
poo_poid mediumint(8) NOT NULL default '0',
poo_option tinytext NOT NULL,
poo_votes smallint(5) NOT NULL default '0',
) TYPE=MyISAM".(empty($__settings['utf8']) ? '' : " DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci");
$queries[] = "CREATE TABLE ".$__settings['dbprefix']."poll_voters (
pv_mid mediumint(8) NOT NULL default '0',
pv_pooid mediumint(10) NOT NULL default '0',
pv_poid mediumint(8) NOT NULL default '0',
UNIQUE KEY pv_mid (pv_mid,pv_pooid,pv_poid)
) TYPE=MyISAM".(empty($__settings['utf8']) ? '' : " DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci");
$queries[] = "CREATE TABLE ".$__settings['dbprefix']."polls (
poid mediumint(8) NOT NULL auto_increment,
poll_qt tinytext NOT NULL,
poll_mid mediumint(8) NOT NULL default '0',
poll_locked tinyint(2) NOT NULL default '0',
poll_tid mediumint(8) NOT NULL default '0',
poll_expiry int(10) NOT NULL default '0',
poll_change_vote tinyint(2) NOT NULL default '0',
poll_started int(10) NOT NULL default '0',
poll_show_when tinyint(2) NOT NULL default '0',
) TYPE=MyISAM".(empty($__settings['utf8']) ? '' : " DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci");
$queries[] = "CREATE TABLE ".$__settings['dbprefix']."posts (
`pid` int(10) NOT NULL auto_increment,
`post_tid` mediumint(8) NOT NULL default '0',
`p_top_sticky` tinyint(2) NOT NULL default '0',
`post_fid` smallint(5) NOT NULL default '0',
`ptime` int(10) NOT NULL default '0',
`poster_id` mediumint(8) NOT NULL default '0',
`poster_ip` varchar(20) NOT NULL default '',
`modtime` int(10) NOT NULL default '0',
`modifiers_id` mediumint(8) NOT NULL default '0',
`use_smileys` tinyint(2) NOT NULL default '1',
`gposter_name` varchar(80) NOT NULL default '',
`gposter_email` varchar(80) NOT NULL default '',
`post_title` varchar(255) NOT NULL default '',
`num_attachments` tinyint(4) NOT NULL default '0',
`par_id` int(10) NOT NULL default '0',
`p_approved` tinyint(2) NOT NULL default '0',
) TYPE=MyISAM".(empty($__settings['utf8']) ? '' : " DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci");
$queries[] = "INSERT INTO ".$__settings['dbprefix']."posts VALUES (1, 1, 0, 1, ".time().", -1, '', 0, 0, 'Hi,\r\n\r\n We would like to thank you for using AEF.\r\nIf you need any assistance :??: , feel free to ask us for help at the [url=http://www.anelectron.com/board/]support board[/url].\r\n\r\nThanks and enjoy AEF!!! ;-D \r\n\r\n', 1, 'AEF Team', 'aef@anelectron.com', '', 0, 0, 1)";
$queries[] = "CREATE TABLE ".$__settings['dbprefix']."read_board (
rb_uid mediumint(8) NOT NULL default '0',
rb_time int(12) NOT NULL default '0',
UNIQUE KEY rb_uid (rb_uid)
) TYPE=MyISAM".(empty($__settings['utf8']) ? '' : " DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci");
$queries[] = "CREATE TABLE ".$__settings['dbprefix']."read_forums (
rf_uid mediumint(8) NOT NULL default '0',
rf_fid smallint(5) NOT NULL default '0',
rf_time int(10) NOT NULL default '0',
UNIQUE KEY rf_uid (rf_uid,rf_fid)
) TYPE=MyISAM".(empty($__settings['utf8']) ? '' : " DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci");
$queries[] = "CREATE TABLE ".$__settings['dbprefix']."read_topics (
rt_uid mediumint(8) NOT NULL default '0',
rt_tid smallint(5) NOT NULL default '0',
rt_time int(10) NOT NULL default '0',
UNIQUE KEY rt_uid (rt_uid,rt_tid)
) TYPE=MyISAM".(empty($__settings['utf8']) ? '' : " DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci");
$queries[] = "CREATE TABLE ".$__settings['dbprefix']."registry (
name varchar(255) NOT NULL default '',
) TYPE=MyISAM".(empty($__settings['utf8']) ? '' : " DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci");
$queries[] = "INSERT INTO ".$__settings['dbprefix']."registry VALUES ('reserved_names', 'admin\r\nwebmaster\r\nmaster\r\nuser\r\nlocalhost\r\nlord')";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."registry VALUES ('latest_mem', '".$__settings['admin_username']."|1')";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."registry VALUES ('num_mem', '1')";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."registry VALUES ('recyclebin', '0')";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."registry VALUES ('mostactive', '1|".time()."')";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."registry VALUES ('maxtopics', '30')";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."registry VALUES ('maxpostsintopics', '15')";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."registry VALUES ('maxreplyhot', '15')";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."registry VALUES ('maxreplyveryhot', '25')";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."registry VALUES ('disableshoutingtopics', '0')";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."registry VALUES ('disableshoutingdesc', '0')";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."registry VALUES ('prenextopic', '1')";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."registry VALUES ('warnoldtopic', '120')";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."registry VALUES ('prefixsticky', 'Sticky:')";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."registry VALUES ('prefixmoved', 'Moved:')";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."registry VALUES ('prefixpolls', 'Poll:')";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."registry VALUES ('maxtitlechars', '0')";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."registry VALUES ('mintitlechars', '0')";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."registry VALUES ('maxdescchars', '0')";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."registry VALUES ('mindescchars', '0')";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."registry VALUES ('allow_taf', '1')";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."registry VALUES ('maxcharposts', '20000')";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."registry VALUES ('mincharposts', '0')";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."registry VALUES ('timepostfromuser', '10')";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."registry VALUES ('maxemotpost', '15')";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."registry VALUES ('maximgspost', '15')";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."registry VALUES ('allowdynimg', '0')";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."registry VALUES ('maximgwidthpost', '300')";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."registry VALUES ('maximgheightpost', '300')";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."registry VALUES ('removenestedquotes', '0')";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."registry VALUES ('attachsigtopost', '1')";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."registry VALUES ('embedflashinpost', '0')";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."registry VALUES ('maxflashpost', '5')";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."registry VALUES ('maxflashwidthinpost', '300')";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."registry VALUES ('maxflashheightinpost', '300')";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."registry VALUES ('enablepolls', '1')";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."registry VALUES ('maxpollsintopic', '3')";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."registry VALUES ('maxoptionspoll', '10')";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."registry VALUES ('maxpollqtlen', '100')";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."registry VALUES ('censor_words_from', '')";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."registry VALUES ('censor_words_to', '')";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."registry VALUES ('maintenance', '0')";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."registry VALUES ('censor_words_case', '0')";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."registry VALUES ('parsebbc', '1')";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."registry VALUES ('autolink', '1')";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."registry VALUES ('bbc_hr', '1')";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."registry VALUES ('bbc_b', '1')";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."registry VALUES ('bbc_i', '1')";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."registry VALUES ('bbc_u', '1')";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."registry VALUES ('bbc_s', '1')";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."registry VALUES ('bbc_left', '1')";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."registry VALUES ('bbc_right', '1')";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."registry VALUES ('bbc_center', '1')";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."registry VALUES ('bbc_size', '1')";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."registry VALUES ('bbc_font', '1')";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."registry VALUES ('bbc_sup', '1')";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."registry VALUES ('bbc_sub', '1')";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."registry VALUES ('bbc_color', '1')";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."registry VALUES ('bbc_url', '1')";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."registry VALUES ('bbc_ftp', '1')";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."registry VALUES ('bbc_email', '1')";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."registry VALUES ('bbc_img', '1')";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."registry VALUES ('bbc_flash', '1')";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."registry VALUES ('bbc_code', '1')";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."registry VALUES ('bbc_quote', '1')";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."registry VALUES ('bbc_php', '1')";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."registry VALUES ('bbc_ul', '1')";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."registry VALUES ('bbc_ol', '1')";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."registry VALUES ('bbc_parseHTML', '1')";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."registry VALUES ('reg_method', '1')";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."registry VALUES ('allow_reg', '1')";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."registry VALUES ('wel_email', '1')";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."registry VALUES ('reg_notify', '0')";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."registry VALUES ('max_pass', '20')";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."registry VALUES ('max_uname', '20')";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."registry VALUES ('min_pass', '4')";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."registry VALUES ('min_uname', '4')";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."registry VALUES ('sec_conf', '1')";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."registry VALUES ('samepc_reg', '0')";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."registry VALUES ('age_limit', '0')";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."registry VALUES ('age_rest_act', '1')";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."registry VALUES ('age_rest_act_address', '')";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."registry VALUES ('age_rest_act_fax', '')";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."registry VALUES ('age_rest_act_tele', '')";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."registry VALUES ('reserved_match_whole', '0')";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."registry VALUES ('reserved_match_insensitive', '1')";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."registry VALUES ('login_failed', '5')";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."registry VALUES ('anon_login', '1')";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."registry VALUES ('fpass_sec_conf', '1')";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."registry VALUES ('userstextlen', '100')";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."registry VALUES ('wwwlen', '150')";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."registry VALUES ('customtitlelen', '30')";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."registry VALUES ('locationlen', '100')";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."registry VALUES ('realnamelen', '100')";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."registry VALUES ('secretqtlen', '200')";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."registry VALUES ('secretansmaxlen', '20')";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."registry VALUES ('secretansminlen', '4')";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."registry VALUES ('usersiglen', '200')";
$queries[] = "INSERT INTO ".$__settings['dbprefix']."registry VALUES ('showavatars', '1')";