\***************************************************************/ //Security-Check if (!defined('APXRUN')) { die('You are not allowed to execute this file directly!'); } //Installieren if (SETUPMODE == 'install') { $mysql = "\n\t\tCREATE TABLE `apx_news` (\n\t\t `id` int(11) unsigned NOT NULL auto_increment,\n\t\t `secid` tinytext NOT NULL,\n\t\t `prodid` int(11) unsigned NOT NULL default '0',\n\t\t `catid` int(11) unsigned NOT NULL default '0',\n\t\t `userid` int(11) unsigned NOT NULL default '0',\n\t\t `send_username` tinytext NOT NULL,\n\t\t `send_email` tinytext NOT NULL,\n\t\t `send_ip` tinytext NOT NULL,\n\t\t `newspic` tinytext NOT NULL,\n\t\t `title` tinytext NOT NULL,\n\t\t `subtitle` tinytext NOT NULL,\n\t\t `teaser` text NOT NULL,\n\t\t `text` mediumtext NOT NULL,\n\t\t `galid` int(11) unsigned NOT NULL default '0',\n\t\t `meta_description` text NOT NULL,\n\t\t `links` text NOT NULL,\n\t\t `addtime` int(11) unsigned NOT NULL default '0',\n\t\t `starttime` int(11) unsigned NOT NULL default '0',\n\t\t `endtime` int(11) unsigned NOT NULL default '0',\n\t\t `top` tinyint(1) unsigned NOT NULL default '0',\n\t\t `sticky` int(11) unsigned NOT NULL default '0',\n\t\t `searchable` tinyint(1) unsigned NOT NULL default '0',\n\t\t `allowcoms` tinyint(1) unsigned NOT NULL default '1',\n\t\t `allowrating` tinyint(1) unsigned NOT NULL default '1',\n\t\t `restricted` tinyint(1) unsigned NOT NULL,\n\t\t `hits` int(11) unsigned NOT NULL default '0',\n\t\t PRIMARY KEY (`id`),\n\t\t KEY `catid` (`catid`),\n\t\t KEY `userid` (`userid`),\n\t\t KEY `starttime` (`starttime`,`endtime`)\n\t\t) ENGINE=MyISAM ;\n\t\t\n\t\tCREATE TABLE `apx_news_cat` (\n\t\t `id` int(11) unsigned NOT NULL auto_increment,\n\t\t `title` tinytext NOT NULL,\n\t\t `icon` tinytext NOT NULL,\n\t\t `open` tinyint(1) unsigned NOT NULL default '1',\n\t\t `forgroup` tinytext NOT NULL,\n\t\t `parents` varchar(255) NOT NULL,\n\t\t `children` text NOT NULL,\n\t\t `ord` tinyint(3) NOT NULL,\n\t\t PRIMARY KEY (`id`),\n\t\t KEY `parents` (`parents`)\n\t\t) ENGINE=MyISAM ;\n\t\t\n\t\tCREATE TABLE `apx_news_sources` (\n\t\t `id` int(11) unsigned NOT NULL auto_increment,\n\t\t `title` tinytext NOT NULL,\n\t\t `link` tinytext NOT NULL,\n\t\t PRIMARY KEY (`id`)\n\t\t) ENGINE=MyISAM ;\n\t\t\n\t\tCREATE TABLE `apx_news_tags` (\n\t\t `id` int(11) unsigned NOT NULL,\n\t\t `tagid` int(11) unsigned NOT NULL,\n\t\t PRIMARY KEY (`id`,`tagid`)\n\t\t) ENGINE=MyISAM;\n\t\t\n\t\tINSERT INTO `apx_config` (`module`, `varname`, `type`, `addnl`, `value`, `tab`, `lastchange`, `ord`) VALUES\n\t\t('news', 'epp', 'int', '', '5', 'VIEW', 1249584889, 1000),\n\t\t('news', 'archiveepp', 'int', '', '5', 'VIEW', 1249584889, 2000),\n\t\t('news', 'archiveall', 'switch', '', '0', 'VIEW', 1249584889, 3000),\n\t\t('news', 'searchepp', 'int', '', '10', 'VIEW', 1249584889, 4000),\n\t\t('news', 'archivesort', 'select', 'a:2:{i:1;s:10:\"{NEWFIRST}\";i:2;s:10:\"{OLDFIRST}\";}', '2', 'VIEW', 1249584889, 5000),\n\t\t('news', 'archiveentrysort', 'select', 'a:2:{i:1;s:10:\"{NEWFIRST}\";i:2;s:10:\"{OLDFIRST}\";}', '1', 'VIEW', 1249584889, 6000),\n\t\t\n\t\t('news', 'searchable', 'switch', '', '1', 'OPTIONS', 1249584889, 1000),\n\t\t('news', 'subcats', 'switch', '', '1', 'OPTIONS', 1249584889, 2000),\n\t\t('news', 'teaser', 'switch', '', '1', 'OPTIONS', 1249584889, 3000),\n\t\t('news', 'coms', 'switch', '', '1', 'OPTIONS', 1249584889, 4000),\n\t\t('news', 'ratings', 'switch', '', '1', 'OPTIONS', 1249584889, 5000),\n\t\t('news', 'archcoms', 'switch', '', '1', 'OPTIONS', 1249584889, 6000),\n\t\t('news', 'archratings', 'switch', '', '1', 'OPTIONS', 1249584889, 7000),\n\t\t('news', 'captcha', 'switch', '', '1', 'OPTIONS', 1249584889, 8000),\n\t\t('news', 'spamprot', 'int', '', '1', 'OPTIONS', 1249584889, 9000),\n\t\t('news', 'mailonnew', 'string', '', '', 'OPTIONS', 1249584889, 10000),\n\t\t\n\t\t('news', 'newspic_width', 'int', '', '120', 'IMAGES', 1249584889, 1000),\n\t\t('news', 'newspic_height', 'int', '', '120', 'IMAGES', 1249584889, 2000),\n\t\t('news', 'newspic_popup', 'switch', '', '1', 'IMAGES', 1249584889, 3000),\n\t\t('news', 'newspic_popup_width', 'int', '', '640', 'IMAGES', 1249584889, 4000),\n\t\t('news', 'newspic_popup_height', 'int', '', '480', 'IMAGES', 1249584889, 5000),\n\t\t('news', 'newspic_quality', 'switch', '', '1', 'IMAGES', 1249584889, 6000);\n\t"; $queries = split_sql($mysql); foreach ($queries as $query) { $db->query($query); } //Newsbilder-Ordner require_once BASEDIR . 'lib/class.mediamanager.php'; $mm = new mediamanager(); $mm->createdir('news'); } elseif (SETUPMODE == 'uninstall') { $mysql = "\n\t\tDROP TABLE `apx_news`;\n\t\tDROP TABLE `apx_news_cat`;\n\t\tDROP TABLE `apx_news_tags`;\n\t\tDROP TABLE `apx_news_sources`;\n\t"; $queries = split_sql($mysql); foreach ($queries as $query) { $db->query($query); } } elseif (SETUPMODE == 'update') { switch ($installed_version) { case 100: //zu 1.0.1 $mysql = "\n\t\t\t\tALTER TABLE `apx_news` ADD `galid` INT( 11 ) UNSIGNED NOT NULL AFTER `text` ;\n\t\t\t\tINSERT INTO `apx_config` VALUES ('news', 'subcats', 'switch', '', '1', '0', '150');\n\t\t\t"; $queries = split_sql($mysql); foreach ($queries as $query) { $db->query($query); }
\***************************************************************/ //Security-Check if (!defined('APXRUN')) { die('You are not allowed to execute this file directly!'); } //Installieren if (SETUPMODE == 'install') { $mysql = "\n\t\tCREATE TABLE `apx_links` (\n\t\t `id` int(11) unsigned NOT NULL auto_increment,\n\t\t `secid` tinytext NOT NULL,\n\t\t `catid` int(11) unsigned NOT NULL default '0',\n\t\t `userid` int(11) unsigned NOT NULL default '0',\n\t\t `send_username` tinytext NOT NULL,\n\t\t `send_email` tinytext NOT NULL,\n\t\t `send_ip` tinytext NOT NULL,\n\t\t `title` tinytext NOT NULL,\n\t\t `url` text NOT NULL,\n\t\t `linkpic` tinytext NOT NULL,\n\t\t `text` text NOT NULL,\n\t\t `meta_description` text NOT NULL,\n\t\t `galid` int(11) unsigned NOT NULL default '0',\n\t\t `addtime` int(11) unsigned NOT NULL default '0',\n\t\t `starttime` int(11) unsigned NOT NULL default '0',\n\t\t `endtime` int(11) unsigned NOT NULL default '0',\n\t\t `broken` int(11) unsigned NOT NULL default '0',\n\t\t `top` tinyint(1) unsigned NOT NULL default '0',\n\t\t `searchable` tinyint(1) unsigned NOT NULL default '0',\n\t\t `allowcoms` tinyint(1) unsigned NOT NULL default '1',\n\t\t `allowrating` tinyint(1) unsigned NOT NULL default '1',\n\t\t `restricted` tinyint(1) unsigned NOT NULL,\n\t\t `hits` int(11) unsigned NOT NULL default '0',\n\t\t PRIMARY KEY (`id`),\n\t\t KEY `catid` (`catid`),\n\t\t KEY `userid` (`userid`),\n\t\t KEY `starttime` (`starttime`,`endtime`)\n\t\t) ENGINE=MyISAM ;\n\t\t\n\t\tCREATE TABLE `apx_links_cat` (\n\t\t `id` int(11) unsigned NOT NULL auto_increment,\n\t\t `title` tinytext NOT NULL,\n\t\t `text` text NOT NULL,\n\t\t `icon` tinytext NOT NULL,\n\t\t `open` tinyint(1) unsigned NOT NULL default '1',\n\t\t `parents` varchar(255) NOT NULL,\n\t\t `children` text NOT NULL,\n\t\t `ord` tinyint(3) NOT NULL,\n\t\t PRIMARY KEY (`id`),\n\t\t KEY `parents` (`parents`)\n\t\t) ENGINE=MyISAM ;\n\t\t\n\t\tCREATE TABLE `apx_links_tags` (\n\t\t `id` int(11) unsigned NOT NULL,\n\t\t `tagid` int(11) unsigned NOT NULL,\n\t\t PRIMARY KEY (`id`,`tagid`)\n\t\t) ENGINE=MyISAM;\n\t\t\n\t\tINSERT INTO `apx_config` (`module`, `varname`, `type`, `addnl`, `value`, `tab`, `lastchange`, `ord`) VALUES\n\t\t('links', 'epp', 'int', '', '20', 'VIEW', 1249981968, 1000),\n\t\t('links', 'searchepp', 'string', '', '20', 'VIEW', 1249981881, 2000),\n\t\t('links', 'catonly', 'switch', '', '1', 'VIEW', 1249981968, 3000),\n\t\t('links', 'sortby', 'select', 'a:2:{i:1;s:7:\"{TITLE}\";i:2;s:6:\"{DATE}\";}', '1', 'VIEW', 1249981968, 4000),\n\t\t('links', 'new', 'int', '', '3', 'VIEW', 1249981968, 5000),\n\t\t\n\t\t('links', 'searchable', 'switch', '', '1', 'OPTIONS', 1249981968, 1000),\n\t\t('links', 'coms', 'switch', '', '1', 'OPTIONS', 1249981968, 2000),\n\t\t('links', 'ratings', 'switch', '', '1', 'OPTIONS', 1249981968, 3000),\n\t\t('links', 'captcha', 'switch', '', '1', 'OPTIONS', 1249981968, 4000),\n\t\t('links', 'spamprot', 'int', '', '1', 'OPTIONS', 1249981968, 5000),\n\t\t('links', 'mailonnew', 'string', '', '', 'OPTIONS', 1249981968, 6000),\n\t\t('links', 'mailonbroken', 'string', '', '', 'OPTIONS', 1249981968, 7000),\n\t\t\n\t\t('links', 'linkpic_width', 'int', '', '120', 'IMAGES', 1249981968, 1000),\n\t\t('links', 'linkpic_height', 'int', '', '120', 'IMAGES', 1249981968, 2000),\n\t\t('links', 'linkpic_popup', 'switch', '', '1', 'IMAGES', 1249981968, 3000),\n\t\t('links', 'linkpic_popup_width', 'int', '', '640', 'IMAGES', 1249981968, 4000),\n\t\t('links', 'linkpic_popup_height', 'int', '', '480', 'IMAGES', 1249981968, 5000),\n\t\t('links', 'linkpic_quality', 'switch', '', '1', 'IMAGES', 1249981968, 6000);\n\t"; $queries = split_sql($mysql); foreach ($queries as $query) { $db->query($query); } //Links-DIR require_once BASEDIR . 'lib/class.mediamanager.php'; $mm = new mediamanager(); $mm->createdir('links'); } elseif (SETUPMODE == 'uninstall') { $mysql = "\n\t\tDROP TABLE `apx_links`;\n\t\tDROP TABLE `apx_links_cat`;\n\t\tDROP TABLE `apx_links_tags`;\n\t"; $queries = split_sql($mysql); foreach ($queries as $query) { $db->query($query); } } elseif (SETUPMODE == 'update') { switch ($installed_version) { case 100: //Zu 1.0.1 $mysql = "\n\t\t\t\tINSERT INTO `apx_config` VALUES ('links', 'mailonnew', 'string', '', '', 0, 1800);\n\t\t\t\tINSERT INTO `apx_config` VALUES ('links', 'captcha', 'switch', '', '0', 0, 1350);\n\t\t\t"; $queries = split_sql($mysql); foreach ($queries as $query) { $db->query($query); }
| SOFTWARE BELONGS TO ITS AUTHORS! | \***************************************************************/ //Security-Check if (!defined('APXRUN')) { die('You are not allowed to execute this file directly!'); } //Installieren if (SETUPMODE == 'install') { $mysql = "\n\t\tCREATE TABLE `apx_gallery` (\n\t\t `id` int(11) unsigned NOT NULL auto_increment,\n\t\t `secid` tinytext NOT NULL,\n\t\t `prodid` int(11) unsigned NOT NULL default '0',\n\t\t `title` tinytext NOT NULL,\n\t\t `description` text NOT NULL,\n\t\t `meta_description` text NOT NULL,\n\t\t `password` tinytext NOT NULL,\n\t\t `preview` tinytext NOT NULL,\n\t\t `addtime` int(11) unsigned NOT NULL default '0',\n\t\t `starttime` int(11) unsigned NOT NULL default '0',\n\t\t `endtime` int(11) unsigned NOT NULL default '0',\n\t\t `lastupdate` INT( 10 ) UNSIGNED NOT NULL,\n\t\t `searchable` tinyint(1) unsigned NOT NULL default '0',\n\t\t `allowcoms` tinyint(1) unsigned NOT NULL,\n\t\t `restricted` tinyint(1) unsigned NOT NULL,\n\t\t `parents` varchar(255) NOT NULL,\n\t\t `children` text NOT NULL,\n\t\t `ord` tinyint(3) NOT NULL,\n\t\t PRIMARY KEY (`id`),\n\t\t KEY `parents` (`parents`),\n\t\t KEY `starttime` (`starttime`,`endtime`,`parents`)\n\t\t) ENGINE=MyISAM ;\n\t\t\n\t\tCREATE TABLE `apx_gallery_pics` (\n\t\t `id` int(11) unsigned NOT NULL auto_increment,\n\t\t `galid` int(11) unsigned NOT NULL default '0',\n\t\t `thumbnail` tinytext NOT NULL,\n\t\t `picture` tinytext NOT NULL,\n\t\t `caption` tinytext NOT NULL,\n\t\t `hits` int(11) unsigned NOT NULL default '0',\n\t\t `addtime` int(11) unsigned NOT NULL default '0',\n\t\t `allowcoms` tinyint(1) unsigned NOT NULL default '1',\n\t\t `allowrating` tinyint(1) unsigned NOT NULL default '1',\n\t\t `active` tinyint(1) unsigned NOT NULL default '0',\n\t\t `potw` tinyint(1) unsigned NOT NULL default '0',\n\t\t PRIMARY KEY (`id`),\n\t\t KEY `galid` (`galid`,`active`),\n\t\t KEY `active` (`active`)\n\t\t) ENGINE=MyISAM ;\n\t\t\n\t\tCREATE TABLE `apx_gallery_tags` (\n\t\t `id` int(11) unsigned NOT NULL,\n\t\t `tagid` int(11) unsigned NOT NULL,\n\t\t PRIMARY KEY (`id`,`tagid`)\n\t\t) ENGINE=MyISAM;\n\t\t\n\t\tINSERT INTO `apx_config` (`module`, `varname`, `type`, `addnl`, `value`, `tab`, `lastchange`, `ord`) VALUES\n\t\t('gallery', 'potw_time', 'int', 'BLOCK', '1249981414', '', 0, 0),\n\t\t\n\t\t('gallery', 'listepp', 'int', '', '5', 'VIEW', 1249816805, 1000),\n\t\t('gallery', 'galepp', 'int', '', '16', 'VIEW', 1249816805, 2000),\n\t\t('gallery', 'ordergal', 'select', 'a:3:{i:1;s:11:\"{ORDERTIME}\";i:2;s:12:\"{ORDERTITLE}\";i:3;s:12:\"{ORDERADMIN}\";}', '1', 'VIEW', 1249816805, 3000),\n\t\t('gallery', 'orderpics', 'select', 'a:2:{i:1;s:10:\"{NEWFIRST}\";i:2;s:10:\"{OLDFIRST}\";}', '1', 'VIEW', 1249816805, 4000),\n\t\t('gallery', 'new', 'int', '', '3', 'VIEW', 1249816805, 5000),\n\t\t\n\t\t('gallery', 'searchable', 'switch', '', '1', 'OPTIONS', 1249816805, 1000),\n\t\t('gallery', 'subgals', 'switch', '', '1', 'OPTIONS', 1249816805, 2000),\n\t\t('gallery', 'coms', 'switch', '', '1', 'OPTIONS', 1249816805, 3000),\n\t\t('gallery', 'galcoms', 'switch', '', '1', 'OPTIONS', 1249816805, 3000),\n\t\t('gallery', 'ratings', 'switch', '', '1', 'OPTIONS', 1249816805, 4000),\n\t\t('gallery', 'potw_auto', 'switch', '', '0', 'OPTIONS', 1249816805, 5000),\n\t\t\n\t\t('gallery', 'addpics', 'int', '', '10', 'IMAGES', 1249816805, 1000),\n\t\t('gallery', 'picwidth', 'int', '', '640', 'IMAGES', 1249816805, 2000),\n\t\t('gallery', 'picheight', 'int', '', '480', 'IMAGES', 1249816805, 3000),\n\t\t('gallery', 'watermark', 'string', '', '', 'IMAGES', 1249816805, 4000),\n\t\t('gallery', 'watermark_transp', 'int', '', '50', 'IMAGES', 1249816805, 5000),\n\t\t('gallery', 'watermark_position', 'select', 'a:9:{i:1;s:18:\"{POSTOP} {POSLEFT}\";i:2;s:20:\"{POSTOP} {POSCENTER}\";i:3;s:19:\"{POSTOP} {POSRIGHT}\";i:4;s:21:\"{POSMIDDLE} {POSLEFT}\";i:5;s:23:\"{POSMIDDLE} {POSCENTER}\";i:6;s:22:\"{POSMIDDLE} {POSRIGHT}\";i:7;s:21:\"{POSBOTTOM} {POSLEFT}\";i:8;s:23:\"{POSBOTTOM} {POSCENTER}\";i:9;s:22:\"{POSBOTTOM} {POSRIGHT}\";}', '9', 'IMAGES', 1249816805, 6000),\n\t\t('gallery', 'thumbwidth', 'int', '', '120', 'IMAGES', 1249816805, 7000),\n\t\t('gallery', 'thumbheight', 'int', '', '90', 'IMAGES', 1249816805, 8000),\n\t\t('gallery', 'quality_resize', 'switch', '', '1', 'IMAGES', 1249816805, 9000),\n\t\t('gallery', 'popup', 'switch', '', '1', 'IMAGES', 1249816805, 10000),\n\t\t('gallery', 'popup_addwidth', 'int', '', '60', 'IMAGES', 1249816805, 12000),\n\t\t('gallery', 'popup_addheight', 'int', '', '150', 'IMAGES', 1249816805, 13000),\n\t\t('gallery', 'popup_resizeable', 'switch', '', '1', 'IMAGES', 1249816805, 14000);\n\t"; $queries = split_sql($mysql); foreach ($queries as $query) { $db->query($query); } require_once BASEDIR . 'lib/class.mediamanager.php'; $mm = new mediamanager(); $mm->createdir('gallery'); $mm->createdir('uploads', 'gallery'); } elseif (SETUPMODE == 'uninstall') { $mysql = "\n\t\tDROP TABLE `apx_gallery`;\n\t\tDROP TABLE `apx_gallery_pics`;\n\t\tDROP TABLE `apx_gallery_tags`;\n\t"; $queries = split_sql($mysql); foreach ($queries as $query) { $db->query($query); } } elseif (SETUPMODE == 'update') { switch ($installed_version) { case 100: //zu 1.0.1 $mysql = "\n\t\t\t\tALTER TABLE `apx_gallery` ADD `endtime` INT( 11 ) UNSIGNED NOT NULL AFTER `starttime`;\n\t\t\t\tUPDATE `apx_gallery` SET endtime='3000000000' WHERE starttime!='0';\n\t\t\t"; $queries = split_sql($mysql); foreach ($queries as $query) { $db->query($query);
$mm->createdir('temp'); } elseif (SETUPMODE == 'update') { switch ($installed_version) { case 100: //zu 1.0.1 $mysql = "\n\t\t\t\tCREATE TABLE `apx_capcha` (\n\t\t\t\t `id` int(11) unsigned NOT NULL auto_increment,\n\t\t\t\t `code` int(5) unsigned NOT NULL default '0',\n\t\t\t\t `hash` tinytext NOT NULL,\n\t\t\t\t `time` int(11) unsigned NOT NULL default '0',\n\t\t\t\t PRIMARY KEY (`id`)\n\t\t\t\t) ENGINE=MyISAM ;\n\t\t\t\tINSERT INTO `apx_config` VALUES ('main', 'textboxwidth', 'int', '', '', '0', '650');\n\t\t\t"; $queries = split_sql($mysql); foreach ($queries as $query) { $db->query($query); } case 101: //zu 1.0.2 //Temp-DIR require_once BASEDIR . 'lib/class.mediamanager.php'; $mm = new mediamanager(); $mm->createdir('temp'); case 102: //Zu 1.0.3 $mysql = "\n\t\t\t\tALTER TABLE `apx_capcha` RENAME `apx_captcha` ;\n\t\t\t\tDELETE FROM `apx_config` WHERE varname='capcha';\n\t\t\t"; $queries = split_sql($mysql); foreach ($queries as $query) { $db->query($query); } case 103: //Zu 1.0.4 $mysql = "\n\t\t\t\tCREATE TABLE `apx_cron` (\n\t\t\t\t `funcname` varchar(50) NOT NULL default '',\n\t\t\t\t `module` varchar(50) NOT NULL default '',\n\t\t\t\t `period` int(11) unsigned NOT NULL default '0',\n\t\t\t\t `lastexec` int(11) unsigned NOT NULL default '0',\n\t\t\t\t `hash` tinytext NOT NULL,\n\t\t\t\t PRIMARY KEY (`funcname`)\n\t\t\t\t) ENGINE=MyISAM;\n\t\t\t\t\n\t\t\t\tALTER TABLE `apx_sections` ADD `lang` VARCHAR( 20 ) NOT NULL AFTER `theme`;\n\t\t\t\tINSERT INTO `apx_config` VALUES ('main', 'tellcaptcha', 'switch', '', '1', '0', '1700');\n\t\t\t"; $queries = split_sql($mysql); foreach ($queries as $query) { $db->query($query); } case 104:
\***************************************************************/ //Security-Check if (!defined('APXRUN')) { die('You are not allowed to execute this file directly!'); } //Installieren if (SETUPMODE == 'install') { $mysql = "\n\t\tCREATE TABLE `apx_forums` (\n\t\t `forumid` int(11) unsigned NOT NULL auto_increment,\n\t\t `iscat` tinyint(1) unsigned NOT NULL default '0',\n\t\t `title` tinytext NOT NULL,\n\t\t `description` text NOT NULL,\n\t\t `meta_description` text NOT NULL,\n\t\t `link` tinytext NOT NULL,\n\t\t `moderator` tinytext NOT NULL,\n\t\t `password` tinytext NOT NULL,\n\t\t `open` tinyint(1) unsigned NOT NULL default '0',\n\t\t `searchable` tinyint(1) unsigned NOT NULL default '0',\n\t\t `countposts` tinyint(1) unsigned NOT NULL default '0',\n\t\t `inherit` tinyint(1) NOT NULL default '0',\n\t\t `stylesheet` tinytext NOT NULL,\n\t\t `right_visible` tinytext NOT NULL,\n\t\t `right_read` tinytext NOT NULL,\n\t\t `right_open` tinytext NOT NULL,\n\t\t `right_announce` tinytext NOT NULL,\n\t\t `right_post` tinytext NOT NULL,\n\t\t `right_editpost` tinytext NOT NULL,\n\t\t `right_delpost` tinytext NOT NULL,\n\t\t `right_delthread` tinytext NOT NULL,\n\t\t `right_addattachment` tinytext NOT NULL,\n\t\t `right_readattachment` tinytext NOT NULL,\n\t\t `parents` varchar(255) NOT NULL default '',\n\t\t `children` text NOT NULL,\n\t\t `lastpost` int(11) unsigned NOT NULL,\n\t\t `lastposter` tinytext NOT NULL,\n\t\t `lastposter_userid` int(11) unsigned NOT NULL default '0',\n\t\t `lastposttime` int(11) unsigned NOT NULL default '0',\n\t\t `lastthread` int(11) unsigned NOT NULL,\n\t\t `lastthread_title` tinytext NOT NULL,\n\t\t `lastthread_icon` int(11) NOT NULL default '-1',\n\t\t `lastthread_prefix` int(11) unsigned NOT NULL,\n\t\t `threads` int(11) unsigned NOT NULL default '0',\n\t\t `posts` int(11) unsigned NOT NULL default '0',\n\t\t `ord` smallint(5) unsigned NOT NULL default '1',\n\t\t PRIMARY KEY (`forumid`),\n\t\t KEY `parents` (`parents`)\n\t\t) ENGINE=MyISAM ;\n\t\t\n\t\tCREATE TABLE `apx_forum_activity` (\n\t\t `userid` int(11) unsigned NOT NULL,\n\t\t `ip` int(11) unsigned NOT NULL,\n\t\t `type` enum('forum','thread') NOT NULL,\n\t\t `id` int(11) unsigned NOT NULL,\n\t\t `time` int(11) unsigned NOT NULL,\n\t\t `invisible` tinyint(1) unsigned NOT NULL,\n\t\t PRIMARY KEY (`userid`,`ip`,`type`,`id`)\n\t\t) ENGINE=MyISAM;\n\t\t\n\t\tCREATE TABLE `apx_forum_anndisplay` (\n\t\t `id` int(11) unsigned NOT NULL,\n\t\t `forumid` int(11) unsigned NOT NULL,\n\t\t PRIMARY KEY (`id`,`forumid`)\n\t\t) ENGINE=MyISAM;\n\t\t\n\t\tCREATE TABLE `apx_forum_announcements` (\n\t\t `id` int(11) unsigned NOT NULL auto_increment,\n\t\t `userid` int(11) unsigned NOT NULL,\n\t\t `title` varchar(255) NOT NULL default '',\n\t\t `text` text NOT NULL,\n\t\t `addtime` int(11) unsigned NOT NULL,\n\t\t `starttime` int(11) unsigned NOT NULL,\n\t\t `endtime` int(11) unsigned NOT NULL,\n\t\t `views` int(11) unsigned NOT NULL default '0',\n\t\t PRIMARY KEY (`id`),\n\t\t KEY `starttime` (`starttime`,`endtime`)\n\t\t) ENGINE=MyISAM ;\n\t\t\n\t\tCREATE TABLE `apx_forum_attachments` (\n\t\t `id` int(11) unsigned NOT NULL auto_increment,\n\t\t `postid` int(11) unsigned NOT NULL default '0',\n\t\t `hash` tinytext NOT NULL,\n\t\t `file` tinytext NOT NULL,\n\t\t `thumbnail` tinytext NOT NULL,\n\t\t `name` tinytext NOT NULL,\n\t\t `size` int(11) unsigned NOT NULL default '0',\n\t\t `mime` tinytext NOT NULL,\n\t\t `time` int(11) unsigned NOT NULL default '0',\n\t\t PRIMARY KEY (`id`),\n\t\t KEY `postid` (`postid`)\n\t\t) ENGINE=MyISAM ;\n\t\t\n\t\tCREATE TABLE `apx_forum_filetypes` (\n\t\t `ext` varchar(10) NOT NULL default '',\n\t\t `icon` tinytext NOT NULL,\n\t\t `size` int(11) unsigned NOT NULL default '0',\n\t\t PRIMARY KEY (`ext`)\n\t\t) ENGINE=MyISAM;\n\t\t\n\t\tCREATE TABLE `apx_forum_index` (\n\t\t `word` varchar(50) NOT NULL default '',\n\t\t `threadid` mediumint(11) unsigned NOT NULL default '0',\n\t\t `postid` int(11) unsigned NOT NULL default '0',\n\t\t `istitle` tinyint(1) unsigned NOT NULL default '0',\n\t\t KEY `word` (`word`),\n\t\t KEY `postid` (`postid`,`istitle`),\n\t\t KEY `threadid` (`threadid`,`istitle`)\n\t\t) ENGINE=MyISAM;\n\t\t\n\t\tCREATE TABLE `apx_forum_posts` (\n\t\t `postid` int(11) unsigned NOT NULL auto_increment,\n\t\t `threadid` int(11) unsigned NOT NULL default '0',\n\t\t `userid` int(11) unsigned NOT NULL default '0',\n\t\t `username` varchar(100) NOT NULL default '',\n\t\t `title` tinytext NOT NULL,\n\t\t `text` mediumtext NOT NULL,\n\t\t `allowsmilies` tinyint(1) unsigned NOT NULL default '0',\n\t\t `allowcodes` tinyint(1) unsigned NOT NULL default '0',\n\t\t `allowsig` tinyint(1) unsigned NOT NULL default '0',\n\t\t `time` int(11) unsigned NOT NULL default '0',\n\t\t `lastedit_by` tinytext NOT NULL,\n\t\t `lastedit_time` int(11) unsigned NOT NULL default '0',\n\t\t `del` tinyint(1) unsigned NOT NULL default '0',\n\t\t `ip` tinytext NOT NULL,\n\t\t `hash` tinytext NOT NULL,\n\t\t PRIMARY KEY (`postid`),\n\t\t KEY `time` (`time`),\n\t\t KEY `threadid` (`threadid`),\n\t\t KEY `del` (`del`),\n\t\t KEY `username` (`username`)\n\t\t) ENGINE=MyISAM ;\n\t\t\n\t\tCREATE TABLE `apx_forum_prefixes` (\n\t\t `prefixid` int(11) unsigned NOT NULL auto_increment,\n\t\t `forumid` int(11) unsigned NOT NULL,\n\t\t `title` tinytext NOT NULL,\n\t\t `code` tinytext NOT NULL,\n\t\t PRIMARY KEY (`prefixid`)\n\t\t) ENGINE=MyISAM ;\n\t\t\n\t\tCREATE TABLE `apx_forum_ranks` (\n\t\t `id` int(11) unsigned NOT NULL auto_increment,\n\t\t `title` text NOT NULL,\n\t\t `color` varchar(6) NOT NULL default '',\n\t\t `image` tinytext NOT NULL,\n\t\t `minposts` int(11) NOT NULL default '-1',\n\t\t `userid` int(11) NOT NULL default '0',\n\t\t `groupid` int(11) unsigned NOT NULL default '0',\n\t\t PRIMARY KEY (`id`),\n\t\t KEY `userid` (`userid`,`groupid`,`minposts`)\n\t\t) ENGINE=MyISAM ;\n\t\t\n\t\tCREATE TABLE `apx_forum_search` (\n\t\t `id` int(11) unsigned NOT NULL auto_increment,\n\t\t `userid` int(11) unsigned NOT NULL default '0',\n\t\t `result` mediumtext NOT NULL,\n\t\t `display` enum('threads','posts') NOT NULL default 'threads',\n\t\t `highlight` text NOT NULL,\n\t\t `ignored` text NOT NULL,\n\t\t `order_field` varchar(20) NOT NULL default '',\n\t\t `order_dir` enum('ASC','DESC') NOT NULL default 'ASC',\n\t\t `time` int(10) unsigned NOT NULL default '0',\n\t\t `hash` varchar(32) NOT NULL,\n\t\t PRIMARY KEY (`id`),\n\t\t KEY `hash` (`hash`,`time`)\n\t\t) ENGINE=MyISAM ;\n\t\t\n\t\tCREATE TABLE `apx_forum_subscriptions` (\n\t\t `id` int(11) unsigned NOT NULL auto_increment,\n\t\t `userid` int(11) unsigned NOT NULL default '0',\n\t\t `type` enum('forum','thread') NOT NULL default 'forum',\n\t\t `source` int(11) unsigned NOT NULL default '0',\n\t\t `notification` enum('none','instant','daily','weekly') NOT NULL default 'none',\n\t\t PRIMARY KEY (`id`),\n\t\t KEY `userid` (`userid`),\n\t\t KEY `notification` (`notification`)\n\t\t) ENGINE=MyISAM ;\n\t\t\n\t\tCREATE TABLE `apx_forum_threads` (\n\t\t `threadid` int(11) unsigned NOT NULL auto_increment,\n\t\t `forumid` int(11) unsigned NOT NULL default '0',\n\t\t `prefix` int(11) unsigned NOT NULL,\n\t\t `title` varchar(255) NOT NULL default '',\n\t\t `icon` int(11) NOT NULL default '-1',\n\t\t `opener` tinytext NOT NULL,\n\t\t `opener_userid` int(11) unsigned NOT NULL default '0',\n\t\t `opentime` int(11) unsigned NOT NULL default '0',\n\t\t `firstpost` int(11) unsigned NOT NULL default '0',\n\t\t `lastposter` tinytext NOT NULL,\n\t\t `lastposter_userid` int(11) unsigned NOT NULL default '0',\n\t\t `lastposttime` int(11) unsigned NOT NULL default '0',\n\t\t `lastpost` int(11) unsigned NOT NULL default '0',\n\t\t `del` tinyint(1) unsigned NOT NULL default '0',\n\t\t `moved` int(11) unsigned NOT NULL default '0',\n\t\t `open` tinyint(1) unsigned NOT NULL default '0',\n\t\t `sticky` tinyint(1) unsigned NOT NULL default '0',\n\t\t `sticky_text` tinytext NOT NULL,\n\t\t `views` int(11) unsigned NOT NULL default '0',\n\t\t `posts` int(11) unsigned NOT NULL default '0',\n\t\t PRIMARY KEY (`threadid`),\n\t\t KEY `forumid` (`forumid`,`del`)\n\t\t) ENGINE=MyISAM ;\n\t\t\n\t\tALTER TABLE `apx_user` ADD `forum_lastactive` INT( 11 ) UNSIGNED NOT NULL , ADD `forum_lastonline` INT( 11 ) UNSIGNED NOT NULL , ADD `forum_posts` INT( 11 ) UNSIGNED NOT NULL ;\n\t\tALTER TABLE `apx_user` ADD `forum_tpp` INT( 11 ) UNSIGNED NOT NULL AFTER `forum_posts` , ADD `forum_ppp` INT( 11 ) UNSIGNED NOT NULL AFTER `forum_tpp` ;\n\t\tALTER TABLE `apx_user` ADD `forum_autosubscribe` TINYINT( 1 ) UNSIGNED NOT NULL DEFAULT '0' AFTER `forum_posts` ;\n\t\tUPDATE `apx_user` SET forum_lastactive=lastactive,forum_lastonline=lastonline;\n\t\t\n\t\tINSERT INTO `apx_cron` VALUES ('subscr_instant', 'forum', 300, 1151708400, '');\n\t\tINSERT INTO `apx_cron` VALUES ('subscr_daily', 'forum', 86400, 1151708400, '');\n\t\tINSERT INTO `apx_cron` VALUES ('subscr_weekly', 'forum', 604800, 1151708400, '');\n\t\tINSERT INTO `apx_cron` VALUES ('subscr_forum_daily', 'forum', 86400, 1151708400, '');\n\t\tINSERT INTO `apx_cron` VALUES ('subscr_forum_weekly', 'forum', 604800, 1151708400, '');\n\t\tINSERT INTO `apx_cron` VALUES ('clean', 'forum', '86400', '1268002800', '');\n\t\t\n\t\tINSERT INTO `apx_config` (`module`, `varname`, `type`, `addnl`, `value`, `tab`, `lastchange`, `ord`) VALUES\n\t\t('forum', 'icons', 'array', 'BLOCK', 'a:6:{i:0;a:2:{s:4:\"file\";s:25:\"/design/smilies/smile.gif\";s:3:\"ord\";i:1;}i:1;a:2:{s:4:\"file\";s:27:\"/design/smilies/shinner.gif\";s:3:\"ord\";i:5;}i:2;a:2:{s:4:\"file\";s:29:\"/design/smilies/angryfire.gif\";s:3:\"ord\";i:4;}i:3;a:2:{s:4:\"file\";s:25:\"/design/smilies/frown.gif\";s:3:\"ord\";i:3;}i:4;a:2:{s:4:\"file\";s:27:\"/design/smilies/biggrin.gif\";s:3:\"ord\";i:0;}i:5;a:2:{s:4:\"file\";s:25:\"/design/smilies/frage.gif\";s:3:\"ord\";i:2;}}', '', 0, 0),\n\t\t('forum', 'rate_possible', 'array_keys', 'BLOCK', 'a:5:{i:1;s:1:\"1\";i:2;s:1:\"2\";i:3;s:1:\"3\";i:4;s:1:\"4\";i:5;s:1:\"5\";}', '', 1146074744, 0),\n\t\t('forum', 'directory', 'string', 'BLOCK', 'forum', '', 0, 0),\n\t\t('forum', 'rate_digits', 'int', 'BLOCK', '0', '', 0, 0),\n\t\t\n\t\t('forum', 'forumtitle', 'string', '', 'apexx Forum', 'VIEW', 1213548598, 1000),\n\t\t('forum', 'tpp', 'int', '', '20', 'VIEW', 1213548598, 2000),\n\t\t('forum', 'ppp', 'int', '', '10', 'VIEW', 1213548598, 3000),\n\t\t('forum', 'hot_posts', 'int', '', '30', 'VIEW', 1213548598, 4000),\n\t\t('forum', 'hot_views', 'int', '', '1000', 'VIEW', 1213548598, 5000),\n\t\t\n\t\t('forum', 'codes', 'switch', '', '1', 'OPTIONS', 1213548598, 1000),\n\t\t('forum', 'smilies', 'switch', '', '1', 'OPTIONS', 1213548598, 2000),\n\t\t('forum', 'badwords', 'switch', '', '1', 'OPTIONS', 1213548598, 3000),\n\t\t('forum', 'edittime', 'int', '', '10', 'OPTIONS', 1213548598, 4000),\n\t\t('forum', 'timeout', 'int', '', '10', 'OPTIONS', 1213548598, 5000),\n\t\t('forum', 'spamprot', 'int', '', '0', 'OPTIONS', 1213548598, 6000),\n\t\t('forum', 'captcha', 'switch', '', '1', 'OPTIONS', 1213548598, 7000),\n\t\t('forum', 'autosubscribe', 'switch', '', '0', 'OPTIONS', 1213548598, 8000),\n\t\t('forum', 'ratings', 'switch', '', '1', 'OPTIONS', 1213548598, 9000);\n\t"; $queries = split_sql($mysql); foreach ($queries as $query) { $db->query($query); } //Forum-DIR require_once BASEDIR . 'lib/class.mediamanager.php'; $mm = new mediamanager(); $mm->createdir('forum'); } elseif (SETUPMODE == 'uninstall') { $mysql = "\n\t\tDROP TABLE `apx_forums`;\n\t\tDROP TABLE `apx_forum_attachments`;\n\t\tDROP TABLE `apx_forum_filetypes`;\n\t\tDROP TABLE `apx_forum_index`;\n\t\tDROP TABLE `apx_forum_posts`;\n\t\tDROP TABLE `apx_forum_ranks`;\n\t\tDROP TABLE `apx_forum_search`;\n\t\tDROP TABLE `apx_forum_subscriptions`;\n\t\tDROP TABLE `apx_forum_threads`;\n\t\t\n\t\tALTER TABLE `apx_user`\n\t\t DROP `forum_lastactive`,\n\t\t DROP `forum_lastonline`,\n\t\t DROP `forum_posts`,\n\t\t DROP `forum_autosubscribe`,\n\t\t DROP `forum_tpp`,\n\t\t DROP `forum_ppp`;\n\t\t\n\t\tDELETE FROM `apx_cron` WHERE funcname IN ('subscr_instant','subscr_daily','subscr_weekly','subscr_forum_daily','subscr_forum_weekly');\n\t"; $queries = split_sql($mysql); foreach ($queries as $query) { $db->query($query); } } elseif (SETUPMODE == 'update') { switch ($installed_version) { case 100: //zu 1.0.1 $mysql = "\n\t\t\t\tINSERT INTO `apx_config` VALUES ('forum', 'rate_digits', 'int', 'BLOCK', '0', '0', '0');\n\t\t\t\tINSERT INTO `apx_config` VALUES ('forum', 'badwords', 'switch', '', '1', '0', '450');\n\t\t\t\tALTER TABLE `apx_forums` ADD `right_addattachment` TINYTEXT NOT NULL AFTER `right_delthread` , ADD `right_readattachment` TINYTEXT NOT NULL AFTER `right_addattachment` ;\n\t\t\t\tUPDATE `apx_forums` SET `right_addattachment` = `right_read`, `right_readattachment` = 'all';\n\t\t\t\tALTER TABLE `apx_forum_attachments` ADD `mime` TINYTEXT NOT NULL AFTER `size` ;\n\t\t\t"; $queries = split_sql($mysql); foreach ($queries as $query) { $db->query($query); }
$db->query($query); } //Locations einfügen /*require_once(BASEDIR.'lib/class.linereader.php'); $locReader = new LineReader(BASEDIR.getmodulepath('user').'locations.sql', ";\n"); $command = ''; while ( ($line = $locReader->getNext())!==false ) { if ( $line ) { $line=str_replace('`apx_','`'.PRE.'_',$line); $db->query($line); } }*/ //User-Gallery-DIR require_once BASEDIR . 'lib/class.mediamanager.php'; $mm = new mediamanager(); $mm->createdir('gallery', 'user'); case 110: //zu 1.1.1 $mysql = "\n\t\t\t\tINSERT INTO `apx_config` VALUES ('user', 'visitorself', 'switch', '', '', '0', '1450');\n\t\t\t\tINSERT INTO `apx_config` VALUES ('user', 'gallery_maxpics', 'int', '', '', '0', '4550');\n\t\t\t\tINSERT INTO `apx_config` VALUES ('user', 'friendsepp', 'int', '', '20', '0', '4800');\n\t\t\t\tINSERT INTO `apx_config` VALUES ('user', 'reportmail', 'string', '', '', '0', '5500');\n\t\t\t\tINSERT INTO `apx_config` VALUES ('user', 'onlinerecord', 'int', 'BLOCK', '', '0', '0');\n\t\t\t\tINSERT INTO `apx_config` VALUES ('user', 'onlinerecord_time', 'int', 'BLOCK', '', '0', '0');\n\t\t\t\tALTER TABLE `apx_user` ADD `locid` INT( 11 ) UNSIGNED NOT NULL AFTER `country` ;\n\t\t\t\tALTER TABLE `apx_user` ADD `pub_usegb` TINYINT( 1 ) UNSIGNED NOT NULL DEFAULT '1' AFTER `pub_showbuddies` ;\n\t\t\t\tALTER TABLE `apx_user_online` CHANGE `ip` `ip` VARCHAR( 15 ) NOT NULL ;\n\t\t\t\tALTER TABLE `apx_user_online` ADD INDEX ( `time` ) ;\n\t\t\t\tDROP TABLE IF EXISTS `apx_user_locations`;\n\t\t\t\t\n\t\t\t\tCREATE TABLE `apx_user_friends` (\n\t\t\t\t `userid` int(11) unsigned NOT NULL,\n\t\t\t\t `friendid` int(11) unsigned NOT NULL,\n\t\t\t\t PRIMARY KEY (`userid`,`friendid`)\n\t\t\t\t) ENGINE=MyISAM;\n\t\t\t\t\n\t\t\t\tCREATE TABLE `apx_user_ignore` (\n\t\t\t\t `userid` int(11) unsigned NOT NULL,\n\t\t\t\t `ignored` int(11) unsigned NOT NULL,\n\t\t\t\t `reason` tinytext NOT NULL,\n\t\t\t\t PRIMARY KEY (`userid`,`ignored`)\n\t\t\t\t) ENGINE=MyISAM;\n\t\t\t\t\n\t\t\t\tCREATE TABLE `apx_user_visits` (\n\t\t\t\t `object` varchar(20) NOT NULL,\n\t\t\t\t `id` int(11) unsigned NOT NULL,\n\t\t\t\t `userid` int(11) unsigned NOT NULL,\n\t\t\t\t `time` int(11) unsigned NOT NULL,\n\t\t\t\t PRIMARY KEY (`object`,`id`,`userid`)\n\t\t\t\t) ENGINE=MyISAM;\n\t\t\t\t\n\t\t\t\tCREATE TABLE `apx_user_locations` (\n\t\t\t\t `id` int(11) NOT NULL,\n\t\t\t\t `name` varchar(250) default NULL,\n\t\t\t\t `b` float default NULL,\n\t\t\t\t `l` float default NULL,\n\t\t\t\t PRIMARY KEY (`id`)\n\t\t\t\t) ENGINE=MyISAM;\n\t\t\t\t\n\t\t\t\tCREATE TABLE `apx_user_locations_plz` (\n\t\t\t\t `locid` int(11) unsigned NOT NULL,\n\t\t\t\t `plz` varchar(5) NOT NULL,\n\t\t\t\t `stamp` varchar(8) NOT NULL,\n\t\t\t\t PRIMARY KEY (`locid`,`plz`),\n\t\t\t\t KEY `stamp` (`stamp`)\n\t\t\t\t) ENGINE=MyISAM;\n\t\t\t"; $queries = split_sql($mysql); foreach ($queries as $query) { $db->query($query); } //Locations einfügen /*require_once(BASEDIR.'lib/class.linereader.php'); $locReader = new LineReader(BASEDIR.getmodulepath('user').'locations.sql', ";\n"); $command = ''; while ( ($line = $locReader->getNext())!==false ) { if ( $line ) { $line=str_replace('`apx_','`'.PRE.'_',$line); $db->query($line);
\***************************************************************/ //Security-Check if (!defined('APXRUN')) { die('You are not allowed to execute this file directly!'); } //Installieren if (SETUPMODE == 'install') { $mysql = "\n\t\tCREATE TABLE IF NOT EXISTS `apx_teaser` (\n\t\t `id` int(11) unsigned NOT NULL AUTO_INCREMENT,\n\t\t `secid` tinytext NOT NULL,\n\t\t `title` tinytext NOT NULL,\n\t\t `text` text NOT NULL,\n\t\t `image` tinytext NOT NULL,\n\t\t `link` tinytext NOT NULL,\n\t\t `group` tinyint(2) unsigned NOT NULL DEFAULT '1',\n\t\t `hits` int(11) unsigned NOT NULL DEFAULT '0',\n\t\t `ord` smallint(4) unsigned NOT NULL DEFAULT '0',\n\t\t `addtime` int(10) unsigned NOT NULL,\n\t\t `starttime` int(10) NOT NULL,\n\t\t `endtime` int(10) NOT NULL,\n\t\t PRIMARY KEY (`id`),\n\t\t KEY `addtime` (`addtime`),\n\t\t KEY `starttime` (`starttime`,`endtime`)\n\t\t) ENGINE=MyISAM;\n\t\t\n\t\tINSERT INTO `apx_config` (`module`, `varname`, `type`, `addnl`, `value`, `tab`, `lastchange`, `ord`) VALUES\n\t\t('teaser', 'orderby', 'select', 'a:3:{i:1;s:12:\"{ORDERADMIN}\";i:2;s:10:\"{ORDERPUB}\";i:3;s:13:\"{ORDERRANDOM}\";}', '2', '', 1129897415, 1000),\n\t\t('teaser', 'groups', 'array', 'BLOCK', 'a:0:{}', '', 0, 0);\n\t"; $queries = split_sql($mysql); foreach ($queries as $query) { $db->query($query); } //Ordner für Bilder require_once BASEDIR . 'lib/class.mediamanager.php'; $mm = new mediamanager(); $mm->createdir('teaser'); } elseif (SETUPMODE == 'uninstall') { $mysql = "\n\t\tDROP TABLE `apx_teaser`;\n\t"; $queries = split_sql($mysql); foreach ($queries as $query) { $db->query($query); } } elseif (SETUPMODE == 'update') { switch ($installed_version) { case 100: //Zu 1.1.0 /* $mysql=" "; $queries=split_sql($mysql);
//zu 1.0.2 $mysql = "\n\t\t\t\tINSERT INTO `apx_config` ( `module` , `varname` , `type` , `addnl` , `value` , `lastchange` , `ord` ) VALUES ('articles', 'searchable', 'switch', '', '1', '0', '50');\n\t\t\t\tALTER TABLE `apx_articles` ADD `searchable` TINYINT( 1 ) UNSIGNED NOT NULL AFTER `sticky` ;\n\t\t\t\tALTER TABLE `apx_articles` ADD `keywords` TINYTEXT NOT NULL AFTER `teaser` ;\n\t\t\t\tUPDATE `apx_articles` SET searchable='1';\n\t\t\t"; $queries = split_sql($mysql); foreach ($queries as $query) { $db->query($query); } case 102: //zu 1.1.0 $mysql = "\n\t\t\t\tCREATE TABLE `apx_articles_previews` (\n\t\t\t\t `artid` int(11) unsigned NOT NULL default '0',\n\t\t\t\t `custom1` tinytext NOT NULL,\n\t\t\t\t `custom2` tinytext NOT NULL,\n\t\t\t\t `custom3` tinytext NOT NULL,\n\t\t\t\t `custom4` tinytext NOT NULL,\n\t\t\t\t `custom5` tinytext NOT NULL,\n\t\t\t\t `custom6` tinytext NOT NULL,\n\t\t\t\t `custom7` tinytext NOT NULL,\n\t\t\t\t `custom8` tinytext NOT NULL,\n\t\t\t\t `custom9` tinytext NOT NULL,\n\t\t\t\t `custom10` tinytext NOT NULL,\n\t\t\t\t `impression` tinytext NOT NULL,\n\t\t\t\t `conclusion` text NOT NULL\n\t\t\t\t) ENGINE=MyISAM;\n\t\t\t\t\n\t\t\t\tCREATE TABLE `apx_articles_reviews` (\n\t\t\t\t `artid` int(11) unsigned NOT NULL default '0',\n\t\t\t\t `custom1` tinytext NOT NULL,\n\t\t\t\t `custom2` tinytext NOT NULL,\n\t\t\t\t `custom3` tinytext NOT NULL,\n\t\t\t\t `custom4` tinytext NOT NULL,\n\t\t\t\t `custom5` tinytext NOT NULL,\n\t\t\t\t `custom6` tinytext NOT NULL,\n\t\t\t\t `custom7` tinytext NOT NULL,\n\t\t\t\t `custom8` tinytext NOT NULL,\n\t\t\t\t `custom9` tinytext NOT NULL,\n\t\t\t\t `custom10` tinytext NOT NULL,\n\t\t\t\t `rate1` tinytext NOT NULL,\n\t\t\t\t `rate2` tinytext NOT NULL,\n\t\t\t\t `rate3` tinytext NOT NULL,\n\t\t\t\t `rate4` tinytext NOT NULL,\n\t\t\t\t `rate5` tinytext NOT NULL,\n\t\t\t\t `rate6` tinytext NOT NULL,\n\t\t\t\t `rate7` tinytext NOT NULL,\n\t\t\t\t `rate8` tinytext NOT NULL,\n\t\t\t\t `rate9` tinytext NOT NULL,\n\t\t\t\t `rate10` tinytext NOT NULL,\n\t\t\t\t `final_rate` tinytext NOT NULL,\n\t\t\t\t `positive` text NOT NULL,\n\t\t\t\t `negative` text NOT NULL,\n\t\t\t\t `conclusion` text NOT NULL,\n\t\t\t\t `award` tinytext NOT NULL\n\t\t\t\t) ENGINE=MyISAM;\n\t\t\t\t\n\t\t\t\tALTER TABLE `apx_articles` ADD `links` TEXT NOT NULL AFTER `galid` ;\n\t\t\t\tALTER TABLE `apx_articles` ADD `type` ENUM( 'normal', 'preview', 'review' ) NOT NULL AFTER `id` ;\n\t\t\t\tALTER TABLE `apx_articles` ADD `pictures` TEXT NOT NULL AFTER `links` ;\n\t\t\t\tALTER TABLE `apx_articles` ADD `pictures_nextid` INT( 11 ) UNSIGNED NOT NULL DEFAULT '1' AFTER `pictures` ;\n\t\t\t\t\n\t\t\t\tUPDATE `apx_config` SET ord = ord +700 WHERE module = 'articles' AND ord >800;\n\t\t\t\tUPDATE `apx_config` SET ord = ord +400 WHERE module = 'articles' AND ord >1600;\n\t\t\t\tINSERT INTO `apx_config` VALUES ('articles', 'picwidth', 'int', '', '640', 1141134229, 900);\n\t\t\t\tINSERT INTO `apx_config` VALUES ('articles', 'picheight', 'int', '', '480', 1141134229, 1000);\n\t\t\t\tINSERT INTO `apx_config` VALUES ('articles', 'watermark', 'string', '', '', 1141134229, 1100);\n\t\t\t\tINSERT INTO `apx_config` VALUES ('articles', 'watermark_transp', 'int', '', '50', 1141134229, 1200);\n\t\t\t\tINSERT INTO `apx_config` VALUES ('articles', 'watermark_position', 'select', 'a:9:{i:1;s:18:\"{POSTOP} {POSLEFT}\";i:2;s:20:\"{POSTOP} {POSCENTER}\";i:3;s:19:\"{POSTOP} {POSRIGHT}\";i:4;s:21:\"{POSMIDDLE} {POSLEFT}\";i:5;s:23:\"{POSMIDDLE} {POSCENTER}\";i:6;s:22:\"{POSMIDDLE} {POSRIGHT}\";i:7;s:21:\"{POSBOTTOM} {POSLEFT}\";i:8;s:23:\"{POSBOTTOM} {POSCENTER}\";i:9;s:22:\"{POSBOTTOM} {POSRIGHT}\";}', '9', 1141134229, 1300);\n\t\t\t\tINSERT INTO `apx_config` VALUES ('articles', 'thumbwidth', 'int', '', '120', 1141134229, 1400);\n\t\t\t\tINSERT INTO `apx_config` VALUES ('articles', 'thumbheight', 'int', '', '90', 1141134229, 1500);\n\t\t\t\tINSERT INTO `apx_config` VALUES ('articles', 'popup_addwidth', 'int', '', '60', 1143727472, 1520);\n\t\t\t\tINSERT INTO `apx_config` VALUES ('articles', 'popup_addheight', 'int', '', '150', 1143727472, 1540);\n\t\t\t\tINSERT INTO `apx_config` VALUES ('articles', 'popup_resizeable', 'switch', '', '1', 1143727472, 1560);\n\t\t\t\tINSERT INTO `apx_config` VALUES ('articles', 'custom_preview', 'array', '', 'a:0:{}', '0', '1700');\n\t\t\t\tINSERT INTO `apx_config` VALUES ('articles', 'custom_review', 'array', '', 'a:0:{}', '0', '1800');\n\t\t\t\tINSERT INTO `apx_config` VALUES ('articles', 'ratefields', 'array', '', 'a:0:{}', '0', '1900');\n\t\t\t\tINSERT INTO `apx_config` VALUES ('articles', 'awards', 'array', '', 'a:0:{}', '0', '2000');\n\t\t\t\tINSERT INTO `apx_config` VALUES ('articles', 'reviews_conclusionpage', 'switch', '', '1', '0', '2025');\n\t\t\t\tINSERT INTO `apx_config` VALUES ('articles', 'previews_conclusionpage', 'switch', '', '1', '0', '2025');\n\t\t\t\tINSERT INTO `apx_config` VALUES ('articles', 'normalonly', 'switch', '', '1', '0', '2050');\n\t\t\t"; $queries = split_sql($mysql); foreach ($queries as $query) { $db->query($query); } require_once BASEDIR . 'lib/class.mediamanager.php'; $mm = new mediamanager(); $mm->createdir('gallery', 'articles'); case 110: //zu 1.1.1 $mysql = "\n\t\t\t\tINSERT INTO `apx_config` VALUES ('articles', 'searchepp', 'int', '', '10', '0', '2800');\n\t\t\t"; $queries = split_sql($mysql); foreach ($queries as $query) { $db->query($query); } case 111: //zu 1.1.2 $mysql = "\n\t\t\t\tINSERT INTO `apx_config` VALUES ('articles', 'archiveentrysort', 'select', 'a:2:{i:1;s:10:\"{NEWFIRST}\";i:2;s:10:\"{OLDFIRST}\";}', '1', 1144936997, 2750);\n\t\t\t"; $queries = split_sql($mysql); foreach ($queries as $query) { $db->query($query); } case 112:
\***************************************************************/ //Security-Check if (!defined('APXRUN')) { die('You are not allowed to execute this file directly!'); } //Installieren if (SETUPMODE == 'install') { $mysql = "\n\t\tCREATE TABLE `apx_products` (\n\t\t `id` int(11) unsigned NOT NULL auto_increment,\n\t\t `prodid` int(11) unsigned NOT NULL,\n\t\t `type` enum('normal','game','music','movie','book','software','hardware') NOT NULL default 'normal',\n\t\t `title` tinytext NOT NULL,\n\t\t `text` text NOT NULL,\n\t\t `picture` tinytext NOT NULL,\n\t\t `teaserpic` TINYTEXT NOT NULL,\n\t\t `website` tinytext NOT NULL,\n\t\t `meta_description` text NOT NULL,\n\t\t `regisseur` tinytext NOT NULL,\n\t\t `actors` tinytext NOT NULL,\n\t\t `manufacturer` int(11) unsigned NOT NULL default '0',\n\t\t `publisher` int(11) unsigned NOT NULL default '0',\n\t\t `genre` int(11) NOT NULL default '0',\n\t\t `systems` tinytext NOT NULL,\n\t\t `sk` enum('','all','none','6','12','16','18') NOT NULL default '',\n\t\t `requirements` text NOT NULL,\n\t\t `equipment` text NOT NULL,\n\t\t `os` tinytext NOT NULL,\n\t\t `languages` tinytext NOT NULL,\n\t\t `license` enum('freeware','shareware','commercial') NOT NULL,\n\t\t `version` tinytext NOT NULL,\n\t\t `isbn` tinytext NOT NULL,\n\t\t `media` tinytext NOT NULL,\n\t\t `length` varchar(50) NOT NULL default '',\n\t\t `custom1` tinytext NOT NULL,\n\t\t `custom2` tinytext NOT NULL,\n\t\t `custom3` tinytext NOT NULL,\n\t\t `custom4` tinytext NOT NULL,\n\t\t `custom5` tinytext NOT NULL,\n\t\t `custom6` tinytext NOT NULL,\n\t\t `custom7` tinytext NOT NULL,\n\t\t `custom8` tinytext NOT NULL,\n\t\t `custom9` tinytext NOT NULL,\n\t\t `custom10` tinytext NOT NULL,\n\t\t `buylink` tinytext NOT NULL,\n\t\t `price` varchar(20) NOT NULL default '0',\n\t\t `recprice` tinytext NOT NULL,\n\t\t `guarantee` tinytext NOT NULL,\n\t\t `addtime` int(11) unsigned NOT NULL default '0',\n\t\t `hits` int(11) unsigned NOT NULL,\n\t\t `active` tinyint(1) unsigned NOT NULL,\n\t\t `allowcoms` tinyint(1) unsigned NOT NULL default '1',\n\t\t `allowrating` tinyint(1) unsigned NOT NULL default '1',\n\t\t `restricted` tinyint(1) unsigned NOT NULL,\n\t\t `top` TINYINT(1) UNSIGNED NOT NULL,\n\t\t `searchable` tinyint(1) unsigned NOT NULL default '0',\n\t\t PRIMARY KEY (`id`),\n\t\t KEY `type` (`type`),\n\t\t KEY `active` (`active`)\n\t\t) ENGINE=MyISAM ;\n\t\t\n\t\tCREATE TABLE `apx_products_coll` (\n\t\t\t`userid` INT( 10 ) UNSIGNED NOT NULL ,\n\t\t\t`prodid` INT( 10 ) UNSIGNED NOT NULL ,\n\t\t\tPRIMARY KEY ( `userid` , `prodid` )\n\t\t) ENGINE = MYISAM ;\n\t\t\n\t\tCREATE TABLE `apx_products_groups` (\n\t\t `id` int(11) unsigned NOT NULL auto_increment,\n\t\t `grouptype` enum('medium','system','genre') NOT NULL default 'medium',\n\t\t `type` enum('normal','game','music','movie','book','software','hardware') NOT NULL default 'game',\n\t\t `title` tinytext NOT NULL,\n\t\t `icon` tinytext NOT NULL,\n\t\t PRIMARY KEY (`id`),\n\t\t KEY `grouptype` (`grouptype`),\n\t\t KEY `type` (`type`)\n\t\t) ENGINE=MyISAM ;\n\t\t\n\t\tCREATE TABLE `apx_products_releases` (\n\t\t `ord` int(11) unsigned NOT NULL auto_increment,\n\t\t `prodid` int(11) unsigned NOT NULL default '0',\n\t\t `system` int(11) unsigned NOT NULL default '0',\n\t\t `data` text NOT NULL,\n\t\t `stamp` int(8) unsigned NOT NULL default '0',\n\t\t PRIMARY KEY (`ord`),\n\t\t KEY `prodid` (`prodid`),\n\t\t KEY `stamp` (`stamp`)\n\t\t) ENGINE=MyISAM ;\n\t\t\n\t\tCREATE TABLE `apx_products_tags` (\n\t\t `id` int(11) unsigned NOT NULL,\n\t\t `tagid` int(11) unsigned NOT NULL,\n\t\t PRIMARY KEY (`id`,`tagid`)\n\t\t) ENGINE=MyISAM;\n\t\t\n\t\tCREATE TABLE `apx_products_units` (\n\t\t `id` int(11) unsigned NOT NULL auto_increment,\n\t\t `type` enum('company','person') NOT NULL default 'company',\n\t\t `title` tinytext NOT NULL,\n\t\t `text` text NOT NULL,\n\t\t `meta_description` text NOT NULL,\n\t\t `fullname` tinytext NOT NULL,\n\t\t `picture` tinytext NOT NULL,\n\t\t `address` tinytext NOT NULL,\n\t\t `email` tinytext NOT NULL,\n\t\t `phone` tinytext NOT NULL,\n\t\t `website` tinytext NOT NULL,\n\t\t `founder` tinytext NOT NULL,\n\t\t `founding_year` tinytext NOT NULL,\n\t\t `founding_country` tinytext NOT NULL,\n\t\t `legalform` tinytext NOT NULL,\n\t\t `headquaters` tinytext NOT NULL,\n\t\t `executive` tinytext NOT NULL,\n\t\t `employees` tinytext NOT NULL,\n\t\t `turnover` tinytext NOT NULL,\n\t\t `sector` tinytext NOT NULL,\n\t\t `products` tinytext NOT NULL,\n\t\t PRIMARY KEY (`id`),\n\t\t KEY `type` (`type`)\n\t\t) ENGINE=MyISAM ;\n\t\t\n\t\tINSERT INTO `apx_config` (`module`, `varname`, `type`, `addnl`, `value`, `tab`, `lastchange`, `ord`) VALUES\n\t\t('products', 'epp', 'int', '', '20', 'VIEW', 1220200389, 1000),\n\t\t('products', 'manu_epp', 'int', '', '20', 'VIEW', 1220200389, 2000),\n\t\t('products', 'manu_searchepp', 'int', '', '20', 'VIEW', '0', '2500'),\n\t\t('products', 'manuprod_epp', 'int', '', '20', 'VIEW', 1220200389, 3000),\n\t\t('products', 'relepp', 'int', '', '20', 'VIEW', 1220200389, 4000),\n\t\t('products', 'searchepp', 'int', '', '20', 'VIEW', 1220200389, 4500),\n\t\t('products', 'sortby', 'select', 'a:2:{i:1;s:7:\"{TITLE}\";i:0;s:9:\"{RELEASE}\";}', '1', 'VIEW', 1220200389, 5000),\n\t\t\n\t\t('products', 'searchable', 'switch', '', '1', 'OPTIONS', 1220200389, 1000),\n\t\t('products', 'coms', 'switch', '', '1', 'OPTIONS', 1220200390, 2000),\n\t\t('products', 'ratings', 'switch', '', '1', 'OPTIONS', 1220200390, 3000),\n\t\t('products', 'filtermanu', 'switch', '', '1', 'OPTIONS', 1220200390, 4000),\n\t\t('products', 'collection', 'switch', '', '1', 'OPTIONS', '0', '5000'),\n\t\t\n\t\t('products', 'custom_normal', 'array', '', 'a:0:{}', 'CUSTOM', 1220200390, 1000),\n\t\t('products', 'custom_game', 'array', '', 'a:0:{}', 'CUSTOM', 1220200390, 2000),\n\t\t('products', 'custom_software', 'array', '', 'a:0:{}', 'CUSTOM', 1220200390, 3000),\n\t\t('products', 'custom_hardware', 'array', '', 'a:0:{}', 'CUSTOM', 1220200390, 4000),\n\t\t('products', 'custom_music', 'array', '', 'a:0:{}', 'CUSTOM', 1220200390, 5000),\n\t\t('products', 'custom_movie', 'array', '', 'a:0:{}', 'CUSTOM', 1220200390, 6000),\n\t\t('products', 'custom_book', 'array', '', 'a:0:{}', 'CUSTOM', 1220200390, 7000),\n\t\t\n\t\t('products', 'pic_width', 'int', '', '120', 'IMAGES', 1220200390, 1000),\n\t\t('products', 'pic_height', 'int', '', '120', 'IMAGES', 1220200390, 2000),\n\t\t('products', 'pic_popup', 'switch', '', '1', 'IMAGES', 1220200390, 3000),\n\t\t('products', 'pic_popup_width', 'int', '', '640', 'IMAGES', 1220200390, 4000),\n\t\t('products', 'pic_popup_height', 'int', '', '480', 'IMAGES', 1220200390, 5000),\n\t\t('products', 'pic_quality', 'switch', '', '1', 'IMAGES', 1220200390, 6000);\n\t"; $queries = split_sql($mysql); foreach ($queries as $query) { $db->query($query); } //Products-DIR require_once BASEDIR . 'lib/class.mediamanager.php'; $mm = new mediamanager(); $mm->createdir('products'); } elseif (SETUPMODE == 'uninstall') { $mysql = "\n\t\tDROP TABLE `apx_products`;\n\t\tDROP TABLE `apx_products_groups`;\n\t\tDROP TABLE `apx_products_releases`;\n\t\tDROP TABLE `apx_products_tags`;\n\t\tDROP TABLE `apx_products_units`;\n\t"; $queries = split_sql($mysql); foreach ($queries as $query) { $db->query($query); } } elseif (SETUPMODE == 'update') { switch ($installed_version) { case 100: //zu 1.0.1 $mysql = "\n\t\t\t\tALTER TABLE `apx_products` ADD `custom1` TINYTEXT NOT NULL AFTER `length` ,ADD `custom2` TINYTEXT NOT NULL AFTER `custom1` ,ADD `custom3` TINYTEXT NOT NULL AFTER `custom2` ,ADD `custom4` TINYTEXT NOT NULL AFTER `custom3` ,ADD `custom5` TINYTEXT NOT NULL AFTER `custom4` ,ADD `custom6` TINYTEXT NOT NULL AFTER `custom5` ,ADD `custom7` TINYTEXT NOT NULL AFTER `custom6` ,ADD `custom8` TINYTEXT NOT NULL AFTER `custom7` ,ADD `custom9` TINYTEXT NOT NULL AFTER `custom8` ,ADD `custom10` TINYTEXT NOT NULL AFTER `custom9` ;\n\t\t\t\tINSERT INTO `apx_config` VALUES ('products', 'custom_normal', 'array', '', 'a:0:{}', '0', '820');\n\t\t\t\tINSERT INTO `apx_config` VALUES ('products', 'custom_game', 'array', '', 'a:0:{}', '0', '830');\n\t\t\t\tINSERT INTO `apx_config` VALUES ('products', 'custom_music', 'array', '', 'a:0:{}', '0', '840');\n\t\t\t\tINSERT INTO `apx_config` VALUES ('products', 'custom_movie', 'array', '', 'a:0:{}', '0', '850');\n\t\t\t\tINSERT INTO `apx_config` VALUES ('products', 'custom_book', 'array', '', 'a:0:{}', '0', '860');\n\t\t\t"; $queries = split_sql($mysql); foreach ($queries as $query) { $db->query($query); }
\***************************************************************/ //Security-Check if (!defined('APXRUN')) { die('You are not allowed to execute this file directly!'); } //Installieren if (SETUPMODE == 'install') { $mysql = "\n\t\tCREATE TABLE `apx_affiliates` (\n\t\t `id` int(11) unsigned NOT NULL auto_increment,\n\t\t `title` tinytext NOT NULL,\n\t\t `image` tinytext NOT NULL,\n\t\t `link` tinytext NOT NULL,\n\t\t `hits` int(11) unsigned NOT NULL default '0',\n\t\t `ord` smallint(4) unsigned NOT NULL default '0',\n\t\t `active` tinyint(1) unsigned NOT NULL default '0',\n\t\t PRIMARY KEY (`id`),\n\t\t KEY `active` (`active`)\n\t\t) ENGINE=MyISAM;\n\t\t\n\t\tINSERT INTO `apx_config` (`module`, `varname`, `type`, `addnl`, `value`, `tab`, `lastchange`, `ord`) VALUES\n\t\t('affiliates', 'orderby', 'select', 'a:4:{i:1;s:12:\"{ORDERADMIN}\";i:2;s:16:\"{ORDERHITS_DESC}\";i:3;s:15:\"{ORDERHITS_ASC}\";i:4;s:13:\"{ORDERRANDOM}\";}', '4', '', 1129897415, 1000);\n\t"; $queries = split_sql($mysql); foreach ($queries as $query) { $db->query($query); } //Ordner für Bilder require_once BASEDIR . 'lib/class.mediamanager.php'; $mm = new mediamanager(); $mm->createdir('affiliates'); } elseif (SETUPMODE == 'uninstall') { $mysql = "\n\t\tDROP TABLE `apx_affiliates`;\n\t"; $queries = split_sql($mysql); foreach ($queries as $query) { $db->query($query); } } elseif (SETUPMODE == 'update') { switch ($installed_version) { case 100: //Zu 1.1.0 //Indizes entfernen clearIndices(PRE . '_affiliates'); //config Update updateConfig('affiliates', "\n\t\t\t\tINSERT INTO `apx_config` (`module`, `varname`, `type`, `addnl`, `value`, `tab`, `lastchange`, `ord`) VALUES\n\t\t\t\t('affiliates', 'orderby', 'select', 'a:4:{i:1;s:12:\"{ORDERADMIN}\";i:2;s:16:\"{ORDERHITS_DESC}\";i:3;s:15:\"{ORDERHITS_ASC}\";i:4;s:13:\"{ORDERRANDOM}\";}', '4', '', 1129897415, 1000);\n\t\t\t"); $mysql = "\n\t\t\t\tALTER TABLE `apx_affiliates` ADD INDEX ( `active` ) ;\n\t\t\t";
foreach ($queries as $query) { $db->query($query); } //Tags erzeugen transformKeywords(PRE . '_downloads', PRE . '_downloads_tags'); case 110: //zu 1.1.1 $mysql = "\n\t\t\t\tALTER TABLE `apx_downloads` ADD `meta_description` TEXT NOT NULL AFTER `text` ;\n\t\t\t"; $queries = split_sql($mysql); foreach ($queries as $query) { $db->query($query); } case 111: //zu 1.1.2 $mysql = "\n\t\t\t\tINSERT INTO `apx_config` VALUES ('downloads', 'mirrorstats', 'switch', '', '1', 'OPTIONS', 1301669229, 4500);\n\t\t\t\tALTER TABLE `apx_downloads` ADD `format` TINYTEXT NOT NULL AFTER `filesize` ;\n\t\t\t"; $queries = split_sql($mysql); foreach ($queries as $query) { $db->query($query); } case 111: //zu 1.1.2 $mysql = "\n\t\t\t\tALTER TABLE `apx_downloads` ADD `teaserpic` TINYTEXT NOT NULL AFTER `text` ;\n\t\t\t\tINSERT INTO `apx_config` (`module`, `varname`, `type`, `addnl`, `value`, `tab`, `lastchange`, `ord`) VALUES\n\t\t\t\t('downloads', 'teaserpic_width', 'int', '', '120', 'TEASERPIC', 1261490672, 1000),\n\t\t\t\t('downloads', 'teaserpic_height', 'int', '', '120', 'TEASERPIC', 1261490672, 2000),\n\t\t\t\t('downloads', 'teaserpic_popup', 'switch', '', '1', 'TEASERPIC', 1261490672, 3000),\n\t\t\t\t('downloads', 'teaserpic_popup_width', 'int', '', '640', 'TEASERPIC', 1261490672, 4000),\n\t\t\t\t('downloads', 'teaserpic_popup_height', 'int', '', '480', 'TEASERPIC', 1261490672, 5000),\n\t\t\t\t('downloads', 'teaserpic_quality', 'switch', '', '1', 'TEASERPIC', 1261490672, 6000);\n\t\t\t"; $queries = split_sql($mysql); foreach ($queries as $query) { $db->query($query); } require_once BASEDIR . 'lib/class.mediamanager.php'; $mm = new mediamanager(); @$mm->createdir('pics', 'downloads'); } }
| SOFTWARE BELONGS TO ITS AUTHORS! | \***************************************************************/ //Security-Check if (!defined('APXRUN')) { die('You are not allowed to execute this file directly!'); } //Installieren if (SETUPMODE == 'install') { $mysql = "\n\t\tCREATE TABLE `apx_videos` (\n\t\t `id` int(11) unsigned NOT NULL auto_increment,\n\t\t `secid` tinytext NOT NULL,\n\t\t `prodid` int(11) unsigned NOT NULL default '0',\n\t\t `catid` int(11) unsigned NOT NULL default '0',\n\t\t `userid` int(11) unsigned NOT NULL default '0',\n\t\t `file` text NOT NULL,\n\t\t `filesize` BIGINT UNSIGNED NOT NULL,\n\t\t `flvfile` tinytext NOT NULL,\n\t\t `status` enum('new','converting','failed','finished') NOT NULL default 'finished',\n\t\t `source` varchar(30) NOT NULL,\n\t\t `title` tinytext NOT NULL,\n\t\t `text` text NOT NULL,\n\t\t `teaserpic` tinytext NOT NULL,\n\t\t `meta_description` text NOT NULL,\n\t\t `addtime` int(11) unsigned NOT NULL default '0',\n\t\t `starttime` int(11) unsigned NOT NULL default '0',\n\t\t `endtime` int(11) unsigned NOT NULL default '0',\n\t\t `broken` int(11) unsigned NOT NULL default '0',\n\t\t `password` tinytext NOT NULL,\n\t\t `limit` int(10) unsigned NOT NULL default '0',\n\t\t `top` tinyint(1) unsigned NOT NULL default '0',\n\t\t `regonly` tinyint(1) unsigned NOT NULL default '0',\n\t\t `searchable` tinyint(1) unsigned NOT NULL default '0',\n\t\t `allowcoms` tinyint(1) unsigned NOT NULL default '1',\n\t\t `allowrating` tinyint(1) unsigned NOT NULL default '1',\n\t\t `restricted` tinyint(1) unsigned NOT NULL,\n\t\t `hits` int(11) unsigned NOT NULL default '0',\n\t\t `downloads` int(11) unsigned NOT NULL,\n\t\t PRIMARY KEY (`id`),\n\t\t KEY `catid` (`catid`),\n\t\t KEY `userid` (`userid`),\n\t\t KEY `starttime` (`starttime`,`endtime`)\n\t\t) ENGINE=MyISAM;\n\t\t\n\t\tCREATE TABLE `apx_videos_cat` (\n\t\t `id` int(11) unsigned NOT NULL auto_increment,\n\t\t `title` tinytext NOT NULL,\n\t\t `text` text NOT NULL,\n\t\t `icon` tinytext NOT NULL,\n\t\t `open` tinyint(1) unsigned NOT NULL default '1',\n\t\t `forgroup` tinytext NOT NULL,\n\t\t `parents` varchar(255) NOT NULL,\n\t\t `children` text NOT NULL,\n\t\t `ord` tinyint(3) NOT NULL,\n\t\t PRIMARY KEY (`id`),\n\t\t KEY `parents` (`parents`)\n\t\t) ENGINE=MyISAM;\n\t\t\n\t\tCREATE TABLE `apx_videos_screens` (\n\t\t `pictureid` int(11) unsigned NOT NULL auto_increment,\n\t\t `videoid` int(11) unsigned NOT NULL,\n\t\t `thumbnail` tinytext NOT NULL,\n\t\t `picture` tinytext NOT NULL,\n\t\t PRIMARY KEY (`pictureid`)\n\t\t) ENGINE=MyISAM;\n\t\t\n\t\tCREATE TABLE `apx_videos_stats` (\n\t\t `daystamp` int(8) unsigned NOT NULL default '0',\n\t\t `time` int(11) unsigned NOT NULL default '0',\n\t\t `dlid` int(11) unsigned NOT NULL default '0',\n\t\t `bytes` bigint(20) unsigned NOT NULL default '0',\n\t\t `hits` int(11) unsigned NOT NULL default '0',\n\t\t PRIMARY KEY (`daystamp`,`dlid`)\n\t\t) ENGINE=MyISAM;\n\t\t\n\t\tCREATE TABLE `apx_videos_tags` (\n\t\t `id` int(11) unsigned NOT NULL,\n\t\t `tagid` int(11) unsigned NOT NULL,\n\t\t PRIMARY KEY (`id`,`tagid`)\n\t\t) ENGINE=MyISAM;\n\t\t\n\t\tINSERT INTO `apx_config` (`module`, `varname`, `type`, `addnl`, `value`, `tab`, `lastchange`, `ord`) VALUES\n\t\t('videos', 'ffmpeg', 'string', 'BLOCK', '', '', 0, 0),\n\t\t('videos', 'flvtool2', 'string', 'BLOCK', '', '', 0, 0),\n\t\t('videos', 'mencoder', 'string', 'BLOCK', '', '', 0, 0),\n\t\t\n\t\t('videos', 'flvwidth', 'int', '', '400', 'CONVERTER', 1261490672, 1000),\n\t\t('videos', 'flvheight', 'int', '', '300', 'CONVERTER', 1261490672, 2000),\n\t\t('videos', 'vbitrate', 'int', '', '1200', 'CONVERTER', 1261490672, 3000),\n\t\t('videos', 'abitrate', 'int', '', '128', 'CONVERTER', 1261490672, 4000),\n\t\t\n\t\t('videos', 'searchable', 'switch', '', '1', 'OPTIONS', 1261490672, 1000),\n\t\t('videos', 'regonly', 'switch', '', '0', 'OPTIONS', 1261490672, 2000),\n\t\t('videos', 'maxtraffic', 'float', '', '0', 'OPTIONS', 1261490672, 3000),\n\t\t('videos', 'exttraffic', 'switch', '', '1', 'OPTIONS', 1251291273, 3500),\n\t\t('videos', 'coms', 'switch', '', '1', 'OPTIONS', 1261490672, 4000),\n\t\t('videos', 'ratings', 'switch', '', '1', 'OPTIONS', 1261490672, 5000),\n\t\t('videos', 'mailonbroken', 'string', '', '', 'OPTIONS', 1261490672, 6000),\n\t\t\n\t\t('videos', 'addpics', 'int', '', '5', 'SCREENSHOTS', 1261490672, 1000),\n\t\t('videos', 'picwidth', 'int', '', '640', 'SCREENSHOTS', 1261490672, 2000),\n\t\t('videos', 'picheight', 'int', '', '480', 'SCREENSHOTS', 1261490672, 3000),\n\t\t('videos', 'watermark', 'string', '', '', 'SCREENSHOTS', 1261490672, 4000),\n\t\t('videos', 'watermark_transp', 'int', '', '50', 'SCREENSHOTS', 1261490672, 5000),\n\t\t('videos', 'watermark_position', 'select', 'a:9:{i:1;s:18:\"{POSTOP} {POSLEFT}\";i:2;s:20:\"{POSTOP} {POSCENTER}\";i:3;s:19:\"{POSTOP} {POSRIGHT}\";i:4;s:21:\"{POSMIDDLE} {POSLEFT}\";i:5;s:23:\"{POSMIDDLE} {POSCENTER}\";i:6;s:22:\"{POSMIDDLE} {POSRIGHT}\";i:7;s:21:\"{POSBOTTOM} {POSLEFT}\";i:8;s:23:\"{POSBOTTOM} {POSCENTER}\";i:9;s:22:\"{POSBOTTOM} {POSRIGHT}\";}', '9', 'SCREENSHOTS', 1261490672, 6000),\n\t\t('videos', 'thumbwidth', 'int', '', '120', 'SCREENSHOTS', 1261490672, 7000),\n\t\t('videos', 'thumbheight', 'int', '', '90', 'SCREENSHOTS', 1261490672, 8000),\n\t\t('videos', 'quality_resize', 'switch', '', '1', 'SCREENSHOTS', 1261490672, 9000),\n\t\t\n\t\t('videos', 'teaserpic_width', 'int', '', '120', 'TEASERPIC', 1261490672, 1000),\n\t\t('videos', 'teaserpic_height', 'int', '', '120', 'TEASERPIC', 1261490672, 2000),\n\t\t('videos', 'teaserpic_popup', 'switch', '', '1', 'TEASERPIC', 1261490672, 3000),\n\t\t('videos', 'teaserpic_popup_width', 'int', '', '640', 'TEASERPIC', 1261490672, 4000),\n\t\t('videos', 'teaserpic_popup_height', 'int', '', '480', 'TEASERPIC', 1261490672, 5000),\n\t\t('videos', 'teaserpic_quality', 'switch', '', '1', 'TEASERPIC', 1261490672, 6000),\n\t\t\n\t\t('videos', 'epp', 'int', '', '20', 'VIEW', 1261490672, 1000),\n\t\t('videos', 'searchepp', 'string', '', '20', 'VIEW', 1261490672, 2000),\n\t\t('videos', 'catonly', 'switch', '', '1', 'VIEW', 1261490672, 3000),\n\t\t('videos', 'sortby', 'select', 'a:2:{i:1;s:7:\"{TITLE}\";i:2;s:6:\"{DATE}\";}', '1', 'VIEW', 1261490672, 4000),\n\t\t('videos', 'new', 'int', '', '3', 'VIEW', 1261490672, 5000),\n\t\t('videos', 'embed_width', 'int', '', '320', 'VIEW', '0', '6000'),\n\t\t('videos', 'embed_height', 'int', '', '240', 'VIEW', '0', '7000');\n\t"; $queries = split_sql($mysql); foreach ($queries as $query) { $db->query($query); } require_once BASEDIR . 'lib/class.mediamanager.php'; $mm = new mediamanager(); $mm->createdir('videos'); $mm->createdir('flv', 'videos'); $mm->createdir('logs', 'videos'); $mm->createdir('pics', 'videos'); $mm->createdir('screens', 'videos'); } elseif (SETUPMODE == 'uninstall') { $mysql = "\n\t\tDROP TABLE `apx_videos`;\n\t\tDROP TABLE `apx_videos_cat`;\n\t\tDROP TABLE `apx_videos_screens`;\n\t\tDROP TABLE `apx_videos_stats`;\n\t\tDROP TABLE `apx_videos_tags`;\n\t"; $queries = split_sql($mysql); foreach ($queries as $query) { $db->query($query); } } elseif (SETUPMODE == 'update') { switch ($installed_version) { case 100: //zu 1.0.1 $mysql = "\n\t\t\t\tALTER TABLE `apx_videos` ADD `filesize` BIGINT UNSIGNED NOT NULL AFTER `file` ;\n\t\t\t\tINSERT INTO `apx_config` VALUES ('videos', 'exttraffic', 'switch', '', '1', 'OPTIONS', 1251291273, 3500);\n\t\t\t";
$apx->tmpl->parse('mygallery_pics'); } else { //GALERIE ERSTELLEN if ($_REQUEST['do'] == 'add') { if ($_POST['send']) { if (!$_POST['title']) { message('back'); } else { $_POST['addtime'] = $_POST['lastupdate'] = time(); $_POST['owner'] = $user->info['userid']; $db->dinsert(PRE . '_user_gallery', 'owner,title,description,password,addtime,lastupdate,allowcoms'); $nid = $db->insert_id(); //Ordner erstellen require_once BASEDIR . 'lib/class.mediamanager.php'; $mm = new mediamanager(); $mm->createdir('gallery-' . $nid, 'user'); message($apx->lang->get('MSG_ADD_OK'), mklink('user.php?action=mygallery', 'user,mygallery.html')); } } $apx->tmpl->assign('POSTTO', mklink('user.php?action=mygallery&do=add', 'user,mygallery.html?do=add')); $apx->tmpl->assign('ALLOWCOMS', 1); $apx->tmpl->assign('ACTION', 'add'); $apx->tmpl->parse('mygallery_addedit'); require 'lib/_end.php'; } elseif ($_REQUEST['do'] == 'edit') { $_REQUEST['id'] = (int) $_REQUEST['id']; if (!$_REQUEST['id']) { die('missing ID!'); } if ($_POST['send']) { if (!$_POST['title']) {
\***************************************************************/ //Security-Check if (!defined('APXRUN')) { die('You are not allowed to execute this file directly!'); } //Installieren if (SETUPMODE == 'install') { $mysql = "\n\t\tCREATE TABLE `apx_calendar_cat` (\n\t\t `id` int(11) unsigned NOT NULL auto_increment,\n\t\t `title` tinytext NOT NULL,\n\t\t `icon` tinytext NOT NULL,\n\t\t `parents` varchar(255) NOT NULL,\n\t\t `children` text NOT NULL,\n\t\t `ord` tinyint(3) NOT NULL,\n\t\t PRIMARY KEY (`id`),\n\t\t KEY `parents` (`parents`)\n\t\t) ENGINE=MyISAM ;\n\t\t\n\t\tCREATE TABLE `apx_calendar_events` (\n\t\t `id` int(11) unsigned NOT NULL auto_increment,\n\t\t `secid` tinytext NOT NULL,\n\t\t `catid` int(11) unsigned NOT NULL default '0',\n\t\t `userid` int(11) unsigned NOT NULL default '0',\n\t\t `send_username` tinytext NOT NULL,\n\t\t `send_email` tinytext NOT NULL,\n\t\t `send_ip` tinytext NOT NULL,\n\t\t `title` tinytext NOT NULL,\n\t\t `text` text NOT NULL,\n\t\t `meta_description` text NOT NULL,\n\t\t `location` tinytext NOT NULL,\n\t\t `location_link` tinytext NOT NULL,\n\t\t `picture` tinytext NOT NULL,\n\t\t `priority` enum('1','2','3') NOT NULL default '2',\n\t\t `galid` int(11) unsigned NOT NULL default '0',\n\t\t `links` text NOT NULL,\n\t\t `addtime` int(11) unsigned NOT NULL default '0',\n\t\t `startday` int(8) NOT NULL default '0',\n\t\t `starttime` smallint(4) NOT NULL default '-1',\n\t\t `endday` int(8) NOT NULL default '0',\n\t\t `endtime` smallint(4) NOT NULL default '-1',\n\t\t `searchable` tinyint(1) unsigned NOT NULL default '0',\n\t\t `allowcoms` tinyint(1) unsigned NOT NULL default '0',\n\t\t `allownote` tinyint(1) unsigned NOT NULL default '0',\n\t\t `restricted` tinyint(1) unsigned NOT NULL,\n\t\t `private` tinyint(1) unsigned NOT NULL default '0',\n\t\t `hits` int(11) unsigned NOT NULL default '0',\n\t\t `active` INT( 11 ) UNSIGNED NOT NULL default '0',\n\t\t PRIMARY KEY (`id`),\n\t\t KEY `catid` (`catid`),\n\t\t KEY `userid` (`userid`),\n\t\t KEY `active` (`active`),\n\t\t KEY `startday` (`startday`,`endday`,`starttime`,`endtime`)\n\t\t) ENGINE=MyISAM ;\n\t\t\n\t\tCREATE TABLE `apx_calendar_parts` (\n\t\t `eventid` int(11) unsigned NOT NULL default '0',\n\t\t `userid` int(11) unsigned NOT NULL default '0',\n\t\t PRIMARY KEY (`eventid`,`userid`)\n\t\t) ENGINE=MyISAM;\n\t\t\n\t\tCREATE TABLE `apx_calendar_tags` (\n\t\t `id` int(11) unsigned NOT NULL,\n\t\t `tagid` int(11) unsigned NOT NULL,\n\t\t PRIMARY KEY (`id`,`tagid`)\n\t\t) ENGINE=MyISAM;\n\t\t\n\t\tINSERT INTO `apx_config` (`module`, `varname`, `type`, `addnl`, `value`, `tab`, `lastchange`, `ord`) VALUES\n\t\t('calendar', 'eventdays', 'int', '', '7', 'VIEW', 1219685244, 1000),\n\t\t('calendar', 'searchepp', 'int', '', '20', 'VIEW', 1219685244, 2000),\n\t\t('calendar', 'sortby', 'select', 'a:2:{i:1;s:13:\"{SORTBY_TIME}\";i:2;s:14:\"{SORTBY_TITLE}\";}', '1', 'VIEW', 1219685244, 3000),\n\t\t('calendar', 'start', 'select', 'a:3:{s:3:\"day\";s:11:\"{START_DAY}\";s:4:\"week\";s:12:\"{START_WEEK}\";s:5:\"month\";s:13:\"{START_MONTH}\";}', 'month', 'VIEW', '0', '4000'),\n\t\t\n\t\t('calendar', 'searchable', 'switch', '', '1', 'OPTIONS', 1219685244, 1000),\n\t\t('calendar', 'subcats', 'switch', '', '1', 'OPTIONS', 1219685244, 2000),\n\t\t('calendar', 'userevents', 'switch', '', '1', 'OPTIONS', 1219685244, 3000),\n\t\t('calendar', 'captcha', 'switch', '', '1', 'OPTIONS', 1219685244, 4000),\n\t\t('calendar', 'mailonnew', 'string', '', '', 'OPTIONS', 1219685244, 5000),\n\t\t('calendar', 'coms', 'switch', '', '1', 'OPTIONS', 1219685244, 6000),\n\t\t('calendar', 'note', 'switch', '', '1', 'OPTIONS', 1219685244, 7000),\n\t\t\n\t\t('calendar', 'pic_width', 'int', '', '120', 'IMAGES', 1219685244, 1000),\n\t\t('calendar', 'pic_height', 'int', '', '120', 'IMAGES', 1219685244, 2000),\n\t\t('calendar', 'pic_popup', 'switch', '', '1', 'IMAGES', 1219685244, 3000),\n\t\t('calendar', 'pic_popup_width', 'int', '', '640', 'IMAGES', 1219685244, 4000),\n\t\t('calendar', 'pic_popup_height', 'int', '', '480', 'IMAGES', 1219685244, 5000),\n\t\t('calendar', 'pic_quality', 'switch', '', '1', 'IMAGES', 1219685244, 6000);\n\t"; $queries = split_sql($mysql); foreach ($queries as $query) { $db->query($query); } //Bilder-Ordner require_once BASEDIR . 'lib/class.mediamanager.php'; $mm = new mediamanager(); $mm->createdir('calendar'); } elseif (SETUPMODE == 'uninstall') { $mysql = "\n\t\tDROP TABLE `apx_calendar_cat`;\n\t\tDROP TABLE `apx_calendar_events`;\n\t\tDROP TABLE `apx_calendar_parts`;\n\t\tDROP TABLE `apx_calendar_tags`;\n\t"; $queries = split_sql($mysql); foreach ($queries as $query) { $db->query($query); } } elseif (SETUPMODE == 'update') { switch ($installed_version) { case 100: //zu 1.0.1 $mysql = "\n\t\t\t\tALTER TABLE `apx_calendar_events` ADD `location` TINYTEXT NOT NULL AFTER `text` ;\n\t\t\t\tALTER TABLE `apx_calendar_events` ADD `send_username` TINYTEXT NOT NULL AFTER `userid` , ADD `send_email` TINYTEXT NOT NULL AFTER `send_username` , ADD `send_ip` TINYTEXT NOT NULL AFTER `send_email` ;\n\t\t\t\tALTER TABLE `apx_calendar_events` ADD `secid` TINYTEXT NOT NULL AFTER `id` ;\n\t\t\t\tUPDATE `apx_calendar_events` SET secid = 'all';\n\t\t\t\tALTER TABLE `apx_calendar_cat` ADD `root_id` INT( 11 ) UNSIGNED NOT NULL AFTER `id` ;\n\t\t\t\tALTER TABLE `apx_calendar_cat` ADD `lft` INT( 11 ) UNSIGNED NOT NULL , ADD `rgt` INT( 11 ) UNSIGNED NOT NULL ;\n\t\t\t\tUPDATE `apx_calendar_cat` SET root_id = id;\n\t\t\t\tINSERT INTO `apx_config` VALUES ('calendar', 'subcats', 'switch', '', '1', 1176245712, 50);\n\t\t\t\tINSERT INTO `apx_config` VALUES ('calendar', 'sortby', 'select', 'a:2:{i:1;s:13:\"{SORTBY_TIME}\";i:2;s:14:\"{SORTBY_TITLE}\";}', '1', '0', '250');\n\t\t\t\tINSERT INTO `apx_config` VALUES ('calendar', 'captcha', 'switch', '', '1', '0', '1050');\n\t\t\t"; $queries = split_sql($mysql); foreach ($queries as $query) { $db->query($query); }
function add() { global $set, $db, $apx; //Sektions-Liste if (!is_array($_POST['secid']) || $_POST['secid'][0] == 'all') { $_POST['secid'] = array('all'); } if ($_POST['send'] == 1) { if (!checkToken()) { infoInvalidToken(); } elseif (!$_POST['title']) { infoNotComplete(); } else { $insert = array('secid' => serialize_section($_POST['secid']), 'prodid' => $_POST['prodid'], 'title' => $_POST['title'], 'description' => $_POST['description'], 'meta_description' => $_POST['meta_description'], 'password' => $_POST['password'], 'addtime' => time(), 'searchable' => $_POST['searchable'], 'restricted' => $_POST['restricted'], 'allowcoms' => $_POST['allowcoms']); //GALERIE FREISCHALTEN if ($apx->user->has_right('gallery.enable') && $_POST['pubnow']) { //Prüfen, ob der Elternknoten deaktiviert ist => falls ja den Knoten deaktivieren if ($_POST['parent'] == 'root') { $insert['starttime'] = time(); $insert['endtime'] = 3000000000; } else { list($parentEnabled) = $db->first("SELECT starttime FROM " . PRE . "_gallery WHERE id='" . intval($_POST['parent']) . "' LIMIT 1"); if ($parentEnabled) { $insert['starttime'] = time(); $insert['endtime'] = 3000000000; } } } //WENN NODE if ($set['gallery']['subgals'] && $_POST['parent'] != 'root') { list($secid) = $db->first("SELECT secid FROM " . PRE . "_gallery WHERE id='" . intval($_POST['parent']) . "' LIMIT 1"); $insert['secid'] = $secid; unset($insert['password'], $insert['restricted']); $nid = $this->cat->createNode(intval($_POST['parent']), $insert); } else { $nid = $this->cat->createNode(0, $insert); } logit('GALLERY_ADD', 'ID #' . $nid); //Tags $tagids = produceTagIds($_POST['tags']); foreach ($tagids as $tagid) { $db->query("INSERT IGNORE INTO " . PRE . "_gallery_tags VALUES('" . $nid . "', '" . $tagid . "')"); } require BASEDIR . 'lib/class.mediamanager.php'; $mm = new mediamanager(); $mm->createdir($nid, 'gallery'); if ($_POST['submit2']) { if ($_REQUEST['updateparent']) { printJSRedirect('action.php?action=gallery.padd&id=' . $nid . '&updateparent=' . $_REQUEST['updateparent']); } else { printJSRedirect('action.php?action=gallery.padd&id=' . $nid); } } else { if ($_REQUEST['updateparent']) { printJSUpdateObject($_REQUEST['updateparent'], get_gallery_list($nid)); } else { printJSRedirect(get_index('gallery.show')); } } } } else { $_POST['searchable'] = 1; $_POST['allowcoms'] = 1; //Mutterelement if ($set['gallery']['subgals']) { $data = $this->cat->getTree(array('title')); if (count($data)) { foreach ($data as $res) { $gallist .= '<option value="' . $res['id'] . '"' . iif($_POST['parent'] == $res['id'], ' selected="selected"') . '>' . str_repeat(' ', $res['level'] - 1) . replace($res['title']) . '</option>'; } } } $apx->tmpl->assign('PARENT', $gallist); $apx->tmpl->assign('SECID', $_POST['secid']); $apx->tmpl->assign('PRODID', $_POST['prodid']); $apx->tmpl->assign('TITLE', compatible_hsc($_POST['title'])); $apx->tmpl->assign('DESCRIPTION', compatible_hsc($_POST['description'])); $apx->tmpl->assign('PASSWORD', compatible_hsc($_POST['password'])); $apx->tmpl->assign('META_DESCRIPTION', compatible_hsc($_POST['meta_description'])); $apx->tmpl->assign('TAGS', compatible_hsc($_POST['tags'])); $apx->tmpl->assign('PUBNOW', (int) $_POST['pubnow']); $apx->tmpl->assign('SEARCHABLE', (int) $_POST['searchable']); $apx->tmpl->assign('RESTRICTED', (int) $_POST['restricted']); $apx->tmpl->assign('ALLOWCOMS', (int) $_POST['allowcoms']); $apx->tmpl->assign('UPDATEPARENT', (int) $_REQUEST['updateparent']); $apx->tmpl->parse('add'); } }