function __construct() { //include_lan(e_PLUGIN.'forum/languages/'.e_LANGUAGE.'/lan_forum_stats.php'); //e107::lan('forum','front'); e107::lan('forum', "front", true); e107::css('forum', 'forum.css'); }
function e_linkwords() { global $pref, $admin_log; /* constructor */ // Do an auto-update on the variable used to hook parsers - so we should only be called once e107::lan('linkwords', e_LANGUAGE); // e_PLUGIN."linkwords/languages/".e_LANGUAGE.".php" $hooks = explode(",", $pref['tohtml_hook']); if (($key = array_search('linkwords', $hooks)) !== FALSE) { unset($hooks[$key]); } if (count($hooks) == 0) { unset($pref['tohtml_hook']); } else { $pref['tohtml_hook'] = implode(',', $hooks); } if (!isset($pref['e_tohtml_list'])) { $pref['e_tohtml_list'] = array(); } if (!in_array('linkwords', $pref['e_tohtml_list'])) { $pref['e_tohtml_list'][] = 'linkwords'; } save_prefs(); e107::getLog()->add('LINKWD_05', LWLAN_58 . '[!br!]' . $pref['tohtml_hook'], ''); // Log that the update was done return; }
<?php /** * @file * This file is loaded every time the core of e107 is included. ie. Wherever * you see require_once("class2.php") in a script. It allows a developer to * modify or define constants, parameters etc. which should be loaded prior to * the header or anything that is sent to the browser as output. It may also be * included in Ajax calls. */ e107::lan('nodejs_comment', false, true); // Register events. $event = e107::getEvent(); $event->register('postcomment', 'nodejs_comment_event_postcomment_callback'); $event->register('login', 'nodejs_comment_event_login_callback'); // TODO: send notifications after comment has been approved. /** * Event callback after triggering "postcomment". * * @param array $comment * Comment item. * * $comment contains: * - comment_pid * - comment_item_id * - comment_subject * - comment_author_id * - comment_author_name * - comment_author_email * - comment_datestamp * - comment_comment
* * Copyright (C) 2009-2014 e107 Inc (e107.org) * Released under the terms and conditions of the * GNU General Public License (http://www.gnu.org/licenses/gpl.txt) * */ if (!defined('e107_INIT')) { require_once "../../class2.php"; } if (!e107::isInstalled('banner')) { e107::redirect(); exit; } e107::includeLan(e_PLUGIN . "banner/languages/" . e_LANGUAGE . "_banner.php"); // TODO e107::lan('banner'); $mes = e107::getMessage(); $frm = e107::getForm(); // When a banner is clicked if (e_QUERY) { $query_string = intval(e_QUERY); $row = $sql->retrieve("banner", "*", "banner_id = '{$query_string}'"); // select the banner $ip = e107::getIPHandler()->getIP(FALSE); $newip = strpos($row['banner_ip'], "{$ip}^") !== FALSE ? $row['banner_ip'] : "{$row['banner_ip']}{$ip}^"; // what does this do? $sql->update("banner", "banner_clicks = banner_clicks + 1, `banner_ip` = '{$newip}' WHERE `banner_id` = '{$query_string}'"); header("Location: {$row['banner_clickurl']}"); exit; } if (!$BANNER_LOGIN_TABLE) {
* $Revision$ * $Date$ * $Author$ */ /** * e107 Linkword plugin * * @package e107_plugins * @subpackage linkwords * @version $Id$; * */ if (!defined('e107_INIT')) { exit; } e107::lan('linkwords', e_LANGUAGE . "_admin_linkwords.php"); if (e_QUERY) { list($action, $junk) = explode('.', e_QUERY . '.'); } else { $action = 'words'; } switch ($action) { case 'options': $text = LAN_LW_HELP_01; break; case 'words': case 'edit': default: $text = LAN_LW_HELP_02; } $ns->tablerender(LAN_LW_HELP_00, $text);
* * $Source: /cvs_backup/e107_0.8/e107_plugins/download/admin_download.php,v $ * $Revision$ * $Date$ * $Author$ */ $eplug_admin = true; define('DOWNLOAD_DEBUG', FALSE); require_once "../../class2.php"; if (!getperms("P") || !e107::isInstalled('download')) { header("location:" . e_BASE . "index.php"); exit; } e107::lan('download', 'download'); // e_PLUGIN.'download/languages/'.e_LANGUAGE.'/download.php' e107::lan('download', 'admin_download'); // e_PLUGIN.'download/languages/'.e_LANGUAGE.'/admin_download.php' // require_once(e_PLUGIN.'download/handlers/adminDownload_class.php'); require_once e_PLUGIN . 'download/handlers/download_class.php'; require_once e_HANDLER . 'upload_handler.php'; require_once e_HANDLER . 'xml_class.php'; require_once e_HANDLER . "form_handler.php"; require_once e_HANDLER . "ren_help.php"; //require_once(e_HANDLER."calendar/calendar_class.ph_"); //$cal = new DHTML_Calendar(true); //$gen = new convert(); $e_sub_cat = 'download'; require_once e_HANDLER . "form_handler.php"; require_once e_HANDLER . "userclass_class.php"; require_once e_HANDLER . "file_class.php"; $fl = new e_file();
<?php /** * @file * Class installations to handle configuration forms on Admin UI. */ require_once '../../class2.php'; if (!getperms('P')) { header('location:' . e_BASE . 'index.php'); exit; } // [PLUGINS]/nodejs_comment/languages/[LANGUAGE]/[LANGUAGE]_admin.php e107::lan('nodejs_comment', true, true); /** * Class nodejs_comment_admin. */ class nodejs_comment_admin extends e_admin_dispatcher { protected $modes = array('main' => array('controller' => 'nodejs_comment_admin_ui', 'path' => null)); protected $adminMenu = array('main/prefs' => array('caption' => LAN_PLUGIN_NODEJS_COMMENT_ADMIN_01, 'perm' => 'P')); protected $menuTitle = LAN_PLUGIN_NODEJS_COMMENT_NAME; } /** * Class nodejs_comment_admin_ui. */ class nodejs_comment_admin_ui extends e_admin_ui { protected $pluginTitle = LAN_PLUGIN_NODEJS_COMMENT_NAME; protected $pluginName = "nodejs_comment"; protected $preftabs = array(LAN_PLUGIN_NODEJS_COMMENT_ADMIN_01); protected $prefs = array('disable_alerts' => array('title' => LAN_PLUGIN_NODEJS_COMMENT_ADMIN_02, 'type' => 'boolean', 'writeParms' => 'label=yesno', 'data' => 'int', 'tab' => 0), 'disable_sounds' => array('title' => LAN_PLUGIN_NODEJS_COMMENT_ADMIN_03, 'type' => 'boolean', 'writeParms' => 'label=yesno', 'data' => 'int', 'tab' => 0), 'comment_display' => array('title' => LAN_PLUGIN_NODEJS_COMMENT_ADMIN_04, 'type' => 'number', 'data' => 'int', 'tab' => 0));
<?php /* * e107 website system * * Copyright (C) 2008-2013 e107 Inc (e107.org) * Released under the terms and conditions of the * GNU General Public License (http://www.gnu.org/licenses/gpl.txt) * */ require_once "../class2.php"; if (!getperms("M")) { header("location:" . e_BASE . "index.php"); exit; } e107::lan('core', 'wmessage', true); class wmessage_admin extends e_admin_dispatcher { protected $modes = array('main' => array('controller' => 'generic_ui', 'path' => null, 'ui' => 'generic_form_ui', 'uipath' => null)); protected $adminMenu = array('main/list' => array('caption' => LAN_MANAGE, 'perm' => 'P'), 'main/create' => array('caption' => LAN_CREATE, 'perm' => 'P'), 'main/prefs' => array('caption' => LAN_PREFS, 'perm' => 'P')); protected $adminMenuAliases = array('main/edit' => 'main/list'); protected $menuTitle = WMLAN_00; } class generic_ui extends e_admin_ui { protected $pluginTitle = WMLAN_00; protected $pluginName = 'core'; protected $eventName = 'wmessage'; protected $table = 'generic'; protected $pid = 'gen_id'; protected $perPage = 10;
$lc = new linkclass(); global $tp; $linkspage_pref = e107::pref('links_page'); $deltest = array_flip($_POST); $from = "0"; if (e_QUERY) { $qs = explode(".", e_QUERY); // needed to have less regex $qs = array_filter($qs, 'strlen'); if (is_numeric($qs[0])) { $from = array_shift($qs); } else { $from = "0"; } } e107::lan('links_page'); $lc->setPageTitle(); //submit comment if (isset($_POST['commentsubmit'])) { if (!$db->select("links_page", "link_id", "link_id = '" . intval($qs[1]) . "' ")) { header("location:" . e_BASE . "index.php"); exit; } else { $row = $db->fetch(); if ($row[0] && (ANON === TRUE || USER === TRUE)) { $cobj->enter_comment($_POST['author_name'], $_POST['comment'], "links_page", $qs[1], $pid, $_POST['subject']); $e107cache->clear("comment.links_page.{$qs[1]}"); } } } //update refer
<?php if (!defined('e107_INIT')) { exit; } /* * This is a 100% Pure Bootstrap Theme for e107 v2 */ define("BOOTSTRAP", true); define("FONTAWESOME", 4); define("VIEWPORT", "width=device-width, initial-scale=1.0"); define("BODYTAG", '<body data-spy="scroll" data-target=".bs-docs-sidebar" >'); e107::lan('theme'); e107::js('bootstrap', 'bootstrap.min.js'); define("CSSORDER", "theme,core,other,plugin,inline"); // TODO try to avoid needing this. - corrects font-awesome overlap issue. if (THEME_STYLE != 'style.css') { switch (THEME_STYLE) { case 'css/superhero.css': e107::css('inline', '@media (min-width: 1000px){ body { padding-top: 100px; } } '); break; case 'amelia.css': e107::css('inline', '@media (min-width: 1000px){ body { padding-top: 70px; } } '); break; default: e107::css('inline', '@media (min-width: 1000px){ body { padding-top: 65px; } } '); break; } } else { e107::css('bootstrap', 'bootstrap.min.css'); e107::css('inline', '@media (min-width: 1000px){ body { padding-top: 75px; }
function __construct() { e107::lan('banner', 'admin', 'true'); }
* */ if (!defined('e107_INIT')) { require_once '../../class2.php'; } define('NAVIGATION_ACTIVE', 'forum'); // ?? $e107 = e107::getInstance(); $tp = e107::getParser(); $ns = e107::getRender(); $mes = e107::getMessage(); if (!$e107->isInstalled('forum')) { header('Location: ' . SITEURL . 'index.php'); exit; } e107::lan('forum', 'English_front'); e107::css('forum', 'forum.css'); class forum_post_handler { private $forumObj; private $action; private $id; private $data; function __construct() { $this->checkForumJump(); require_once e_PLUGIN . 'forum/forum_class.php'; // includes LAN file. $forum = new e107forum(); $this->forumObj = $forum; $this->action = trim($_GET['f']);
/* * e107 website system * * Copyright (C) 2008-2013 e107 Inc (e107.org) * Released under the terms and conditions of the * GNU General Public License (http://www.gnu.org/licenses/gpl.txt) * * File Upload facility - administration * */ require_once '../class2.php'; if (!getperms('V')) { header('location:' . e_BASE . 'index.php'); exit; } e107::lan('core', 'upload', 'admin'); $e_sub_cat = 'upload'; // Generated e107 Plugin Admin Area class upload_admin extends e_admin_dispatcher { protected $modes = array('main' => array('controller' => 'upload_ui', 'path' => null, 'ui' => 'upload_form_ui', 'uipath' => null)); protected $adminMenu = array('main/list' => array('caption' => LAN_MANAGE, 'perm' => 'V')); protected $adminMenuAliases = array('main/edit' => 'main/list'); protected $menuTitle = 'Upload'; } class upload_ui extends e_admin_ui { protected $pluginTitle = 'Upload'; protected $pluginName = 'core'; protected $table = 'upload'; protected $pid = 'upload_id';
| Released under the terms and conditions of the | GNU General Public License (http://gnu.org). | | $URL$ | $Revision$ | $Id$ | $Author$ +----------------------------------------------------------------------------+ */ ini_set('zlib.output_compression', 0); header('Content-Encoding: none'); // turn off gzip. ob_implicit_flush(true); ob_end_flush(); require_once '../class2.php'; e107::lan('core', 'fileinspector', true); if (!getperms('Y')) { header('location:' . e_BASE . 'index.php'); exit; } $error_handler->debug = FALSE; require_once e_HANDLER . 'form_handler.php'; $DOCS_DIRECTORY = $HELP_DIRECTORY; // Give a sensible, albeit probably invalid, value if (substr($HELP_DIRECTORY, -5, 5) == 'help/') { $DOCS_DIRECTORY = substr($HELP_DIRECTORY, 0, -5); // Whatever $HELP_DIRECTORY is set to, assume docs are in a subdirectory called 'help' off it } $maindirs = array('admin' => $ADMIN_DIRECTORY, 'files' => $FILES_DIRECTORY, 'images' => $IMAGES_DIRECTORY, 'themes' => $THEMES_DIRECTORY, 'plugins' => $PLUGINS_DIRECTORY, 'handlers' => $HANDLERS_DIRECTORY, 'languages' => $LANGUAGES_DIRECTORY, 'downloads' => $DOWNLOADS_DIRECTORY, 'docs' => $DOCS_DIRECTORY); foreach ($maindirs as $maindirs_key => $maindirs_value) { $coredir[$maindirs_key] = substr($maindirs_value, 0, -1);
<?php /* * e107 website system * * Copyright (C) 2008-2009 e107 Inc (e107.org) * Released under the terms and conditions of the * GNU General Public License (http://www.gnu.org/licenses/gpl.txt) * * Administration Area - Update Admin * * */ require_once '../class2.php'; // include_lan(e_LANGUAGEDIR.e_LANGUAGE.'/admin/lan_'.e_PAGE); e107::lan('core', 'updateadmin', true); $e_sub_cat = 'admin_pass'; require_once e_ADMIN . 'auth.php'; // require_once(e_HANDLER.'user_handler.php'); //use e107::getUserSession() instead. require_once e_HANDLER . 'validator_class.php'; $userMethods = e107::getUserSession(); $mes = e107::getMessage(); $frm = e107::getForm(); if (isset($_POST['update_settings'])) { if ($_POST['ac'] == md5(ADMINPWCHANGE)) { $userData = array(); $userData['data'] = array(); if ($_POST['a_password'] != '' && $_POST['a_password2'] != '' && $_POST['a_password'] == $_POST['a_password2']) { $userData['data']['user_password'] = $sql->escape($userMethods->HashPassword($_POST['a_password'], $currentUser['user_loginname']), FALSE); unset($_POST['a_password']); unset($_POST['a_password2']);
/* * e107 website system * * Copyright (C) 2008-2015 e107 Inc (e107.org) * Released under the terms and conditions of the * GNU General Public License (http://www.gnu.org/licenses/gpl.txt) * * Linkwords plugin - admin page * */ require_once '../../class2.php'; if (!getperms('P') || !e107::isInstalled('linkwords')) { header('location:' . e_BASE . 'index.php'); exit; } e107::lan('linkwords', true); // e_PLUGIN.'linkwords/languages/'.e_LANGUAGE.'_admin.php' define('LW_CACHE_TAG', 'nomd5_linkwords'); class linkwords_admin extends e_admin_dispatcher { protected $modes = array('main' => array('controller' => 'linkwords_ui', 'path' => null, 'ui' => 'linkwords_form_ui', 'uipath' => null)); protected $adminMenu = array('main/list' => array('caption' => LAN_MANAGE, 'perm' => 'P'), 'main/create' => array('caption' => LAN_CREATE, 'perm' => 'P'), 'main/prefs' => array('caption' => LAN_PREFS, 'perm' => 'P')); protected $adminMenuAliases = array('main/edit' => 'main/list'); protected $menuTitle = LAN_PLUGIN_LINKWORDS_NAME; } class linkwords_ui extends e_admin_ui { protected $pluginTitle = 'Linkwords'; protected $pluginName = 'core'; // protected $eventName = 'linkwords-linkwords'; // remove comment to enable event triggers in admin. protected $table = 'linkwords';
/* * e107 website system * * Copyright (C) 2008-2014 e107 Inc (e107.org) * Released under the terms and conditions of the * GNU General Public License (http://www.gnu.org/licenses/gpl.txt) * */ $eplug_admin = true; require_once '../../class2.php'; if (!getperms('P')) { header('location:' . e_BASE . 'index.php'); exit; } e107::includeLan(e_PLUGIN . 'forum/languages/' . e_LANGUAGE . '/English_admin.php'); e107::lan('forum', '', 'front'); $legacy = false; if (E107_DEBUG_LEVEL > 0 && $legacy == true) { define('OLD_FORUMADMIN', true); //e107::getMessage()->addwarning("Experimental code now active. Using this page in debug mode active could break your forum configuration."); } // Generated e107 Plugin Admin Area if (!deftrue('OLD_FORUMADMIN')) { class forum_admin extends e_admin_dispatcher { protected $modes = array('main' => array('controller' => 'forum_ui', 'path' => null, 'ui' => 'forum_form_ui', 'uipath' => null), 'mods' => array('controller' => 'forum_ui', 'path' => null, 'ui' => 'forum_form_ui', 'uipath' => null), 'report' => array('controller' => 'reported_ui', 'path' => null, 'ui' => 'reported_form_ui', 'uipath' => null), 'post' => array('controller' => 'post_ui', 'path' => null, 'ui' => 'post_form_ui', 'uipath' => null)); protected $adminMenu = array('main/list' => array('caption' => LAN_MANAGE, 'perm' => 'P'), 'main/create' => array('caption' => LAN_CREATE, 'perm' => 'P'), 'opt1' => array('divider' => true), 'main/rules' => array('caption' => WMGLAN_5, 'perm' => 'P'), 'mods/list' => array('caption' => LAN_FORUM_2003, 'perm' => 'P'), 'main/prefs' => array('caption' => LAN_PREFS, 'perm' => 'P'), 'opt2' => array('divider' => true), 'report/list' => array('caption' => FORLAN_116, 'perm' => 'P'), 'post/list' => array('caption' => "Latest Posts", 'perm' => 'P'), 'main/prune' => array('caption' => LAN_PRUNE, 'perm' => 'P'), 'main/tools' => array('caption' => FORLAN_153, 'perm' => 'p')); protected $adminMenuAliases = array('main/edit' => 'main/list'); protected $menuTitle = 'Forum'; function init() {
* * Copyright (C) 2008-2013 e107 Inc (e107.org) * Released under the terms and conditions of the * GNU General Public License (http://www.gnu.org/licenses/gpl.txt) * * Plugin Administration - gsitemap * */ require_once "../../class2.php"; if (!getperms("P") || !e107::isInstalled('gsitemap')) { e107::redirect('admin'); exit; } require_once e_ADMIN . "auth.php"; require_once e_HANDLER . "userclass_class.php"; e107::lan('gsitemap', e_LANGUAGE . "_admin_gsitemap.php"); $gsm = new gsitemap(); class gsitemap { var $message; var $freq_list = array(); function gsitemap() { /* constructor */ $mes = e107::getMessage(); $this->freq_list = array("always" => GSLAN_11, "hourly" => GSLAN_12, "daily" => GSLAN_13, "weekly" => GSLAN_14, "monthly" => GSLAN_15, "yearly" => GSLAN_16, "never" => LAN_NEVER); if (isset($_POST['edit'])) { $this->editSme(); } if (isset($_POST['delete'])) { $this->deleteSme();
* Copyright (C) 2008-2013 e107 Inc (e107.org) * Released under the terms and conditions of the * GNU General Public License (http://www.gnu.org/licenses/gpl.txt) * */ require_once '../../class2.php'; $e107 = e107::getInstance(); if (!$e107->isInstalled('forum')) { e107::redirect('admin'); exit; } $ns = e107::getRender(); $tp = e107::getParser(); require_once e_PLUGIN . 'forum/forum_class.php'; $forum = new e107forum(); e107::lan('forum', 'admin'); //include_lan(e_PLUGIN.'forum/languages/'.e_LANGUAGE.'/lan_forum_conf.php'); $e_sub_cat = 'forum'; if (!USER || !isset($_GET['f']) || !isset($_GET['id'])) { header('location:' . $e107::getUrl()->create('/'), array(), array('encode' => false, 'full' => 1)); exit; } $id = (int) $_GET['id']; $action = $_GET['f']; $qry = "\nSELECT t.*, f.*, fp.forum_id AS forum_parent_id FROM #forum_thread as t\nLEFT JOIN #forum AS f ON t.thread_forum_id = f.forum_id\nLEFT JOIN #forum AS fp ON fp.forum_id = f.forum_parent\nWHERE t.thread_id = {$thread_id}\n"; $threadInfo = $forum->threadGet($id); $modList = $forum->forumGetMods($threadInfo->forum_moderators); //var_dump($threadInfo); //var_dump($modList); //If user is not a moderator of indicated forum, redirect to index page if (!in_array(USERID, array_keys($modList))) {
* e107 Banner management plugin * * Handles the display and sequencing of banners on web pages, including counting impressions * * @package e107_plugins * @subpackage banner * */ require_once '../../class2.php'; if (!getperms('D') && !getperms('P')) { header('location:' . e_BASE . 'index.php'); exit; } $e_sub_cat = 'banner'; e107::lan('banner', false, 'front'); e107::lan('banner', true, true); class banner_admin extends e_admin_dispatcher { protected $modes = array('main' => array('controller' => 'banner_ui', 'path' => null, 'ui' => 'banner_form_ui', 'uipath' => null)); protected $adminMenu = array('main/list' => array('caption' => LAN_MANAGE, 'perm' => 'P'), 'main/create' => array('caption' => LAN_CREATE, 'perm' => 'P'), 'main/menu' => array('caption' => BNRLAN_36, 'perm' => 'P')); protected $adminMenuAliases = array('main/edit' => 'main/list'); protected $menuTitle = 'Banners'; } class banner_ui extends e_admin_ui { protected $pluginTitle = 'Banners'; protected $pluginName = 'banner'; protected $table = 'banner'; protected $pid = 'banner_id'; protected $perPage = 10; protected $batchDelete = true;
function pluginRenderPlugin($pluginList) { global $plugin; if (empty($pluginList)) { return ''; } $tp = e107::getParser(); $frm = e107::getForm(); $pgf = new pluginmanager_form(); $text = ""; foreach ($pluginList as $plug) { e107::loadLanFiles($plug['plugin_path'], 'admin'); if ($this->action == "avail") { e107::lan($plug['plugin_path'], 'global', true); // Load language files. } $_path = e_PLUGIN . $plug['plugin_path'] . '/'; $plug_vars = false; $plugin_config_icon = ""; if ($plugin->parse_plugin($plug['plugin_path'])) { $plug_vars = $plugin->plug_vars; } if (varset($plug['plugin_category']) == "menu") { continue; } if ($plug_vars) { $icon_src = (isset($plug_vars['plugin_php']) ? e_PLUGIN : $_path) . $plug_vars['administration']['icon']; $plugin_icon = $plug_vars['administration']['icon'] ? $icon_src : $tp->toGlyph('e-cat_plugins-32'); $conf_file = "#"; $conf_title = ""; if ($plug_vars['administration']['configFile'] && $plug['plugin_installflag'] == true) { $conf_file = e_PLUGIN . $plug['plugin_path'] . '/' . $plug_vars['administration']['configFile']; $conf_title = LAN_CONFIGURE . ' ' . $tp->toHtml($plug_vars['@attributes']['name'], "", "defs,emotes_off, no_make_clickable"); // $plugin_icon = "<a title='{$conf_title}' href='{$conf_file}' >".$plugin_icon."</a>"; $plugin_config_icon = "<a class='btn btn-default' title='{$conf_title}' href='{$conf_file}' >" . ADMIN_CONFIGURE_ICON . "</a>"; } $plugEmail = varset($plug_vars['author']['@attributes']['email'], ''); $plugAuthor = varset($plug_vars['author']['@attributes']['name'], ''); $plugURL = varset($plug_vars['author']['@attributes']['url'], ''); $plugDate = varset($plug_vars['@attributes']['date'], ''); $compatibility = varset($plug_vars['@attributes']['compatibility'], ''); $description = varset($plug_vars['description']['@attributes']['lang']) ? $tp->toHTML($plug_vars['description']['@attributes']['lang'], false, "defs,emotes_off, no_make_clickable") : $tp->toHTML($plug_vars['description']['@value'], false, "emotes_off, no_make_clickable"); $plugReadme = ""; if (varset($plug['plugin_installflag'])) { $plugName = "<a title='{$conf_title}' href='{$conf_file}' >" . $tp->toHTML($plug['plugin_name'], false, "defs,emotes_off, no_make_clickable") . "</a>"; } else { $plugName = $tp->toHTML($plug['plugin_name'], false, "defs,emotes_off, no_make_clickable"); } if (varset($plug_vars['readme'])) { $plugReadme = $plug_vars['readme']; } if (varset($plug_vars['readMe'])) { $plugReadme = $plug_vars['readMe']; } if (!file_exists($plugin_icon)) { $plugin_icon = 'e-cat_plugins-32'; // e_IMAGE."admin_images/cat_plugins_32.png"; } $data = array('plugin_id' => $plug['plugin_id'], 'plugin_icon' => $plugin_icon, 'plugin_name' => $plugName, 'plugin_folder' => $plug['plugin_path'], 'plugin_date' => $plugDate, 'plugin_category' => vartrue($plug['plugin_category']), 'plugin_author' => vartrue($plugAuthor), 'plugin_version' => $plug['plugin_version'], 'plugin_description' => $description, 'plugin_compatible' => $this->compatibilityLabel($plug_vars['@attributes']['compatibility']), 'plugin_website' => vartrue($row['authorUrl']), 'plugin_notes' => ''); $pgf->plug_vars = $plug_vars; $pgf->plug = $plug; $text .= $pgf->renderTableRow($this->fields, $this->fieldpref, $data, 'plugin_id'); /* //LEGACY CODE $text .= "<tr>"; if(varset($this-> fields['checkboxes'])) { $rowid = "checkboxes[".$plug['plugin_id']."]"; $text .= "<td class='center middle'>".$frm->checkbox($rowid, $plug['plugin_id'])."</td>\n"; } // $text .= (in_array("plugin_status",$this->fieldpref)) ? "<td class='center'>".$img."</td>" : ""; $text .= (in_array("plugin_icon",$this->fieldpref)) ? "<td class='center middle'>".$plugin_icon."</td>" : ""; $text .= (in_array("plugin_name",$this->fieldpref)) ? "<td class='middle'>".$plugName."</td>" : ""; $text .= (in_array("plugin_version",$this->fieldpref)) ? "<td class='middle'>".$plug['plugin_version']."</td>" : ""; $text .= (in_array("plugin_date",$this->fieldpref)) ? "<td class='middle'>".$plugDate."</td>" : ""; $text .= (in_array("plugin_folder",$this->fieldpref)) ? "<td class='middle'>".$plug['plugin_path']."</td>" : ""; $text .= (in_array("plugin_category",$this->fieldpref)) ? "<td class='middle'>".$plug['plugin_category']."</td>" : ""; $text .= (in_array("plugin_author",$this->fieldpref)) ? "<td class='middle'><a href='mailto:".$plugEmail."' title='".$plugEmail."'>".$plugAuthor."</a> </td>" : ""; $text .= (in_array("plugin_website",$this->fieldpref)) ? "<td class='center middle'>".($plugURL ? "<a href='{$plugURL}' title='{$plugURL}' >".ADMIN_URL_ICON."</a>" : "")."</td>" : ""; $text .= (in_array("plugin_compatible",$this->fieldpref)) ? "<td class='center middle'>".$this->compatibilityLabel($plug_vars['@attributes']['compatibility'])."</td>" : ""; $text .= (in_array("plugin_description",$this->fieldpref)) ? "<td class='middle'>".$description."</td>" : ""; $text .= (in_array("plugin_compliant",$this->fieldpref)) ? "<td class='center middle'>".((varset($plug_vars['compliant']) || varsettrue($plug_vars['@attributes']['xhtmlcompliant'])) ? ADMIN_TRUE_ICON : " ")."</td>" : ""; $text .= (in_array("plugin_notes",$this->fieldpref)) ? "<td class='center middle'>".($plugReadme ? "<a href='".e_PLUGIN.$plug['plugin_path']."/".$plugReadme."' title='".$plugReadme."'>".ADMIN_INFO_ICON."</a>" : " ")."</td>" : ""; // Plugin options Column -------------- $text .= "<td class='options center middle'> <div class='btn-group'>".$plugin_config_icon; if ($plug_vars['@attributes']['installRequired']) { if ($plug['plugin_installflag']) { $text .= ($plug['plugin_installflag'] ? "<a class='btn' href=\"".e_SELF."?uninstall.{$plug['plugin_id']}\" title='".EPL_ADLAN_1."' >".ADMIN_UNINSTALLPLUGIN_ICON."</a>" : "<a class='btn' href=\"".e_SELF."?install.{$plug['plugin_id']}\" title='".EPL_ADLAN_0."' >".ADMIN_INSTALLPLUGIN_ICON."</a>"); // $text .= ($plug['plugin_installflag'] ? "<button type='button' class='delete' value='no-value' onclick=\"location.href='".e_SELF."?uninstall.{$plug['plugin_id']}'\"><span>".EPL_ADLAN_1."</span></button>" : "<button type='button' class='update' value='no-value' onclick=\"location.href='".e_SELF."?install.{$plug['plugin_id']}'\"><span>".EPL_ADLAN_0."</span></button>"); if (PLUGIN_SHOW_REFRESH && !varsettrue($plug_vars['plugin_php'])) { $text .= "<br /><br /><input type='button' class='btn button' onclick=\"location.href='".e_SELF."?refresh.{$plug['plugin_id']}'\" title='".'Refresh plugin settings'."' value='".'Refresh plugin settings'."' /> "; } } else { // $text .= "<input type='button' class='btn' onclick=\"location.href='".e_SELF."?install.{$plug['plugin_id']}'\" title='".EPL_ADLAN_0."' value='".EPL_ADLAN_0."' />"; // $text .= "<button type='button' class='update' value='no-value' onclick=\"location.href='".e_SELF."?install.{$plug['plugin_id']}'\"><span>".EPL_ADLAN_0."</span></button>"; $text .= "<a class='btn' href=\"".e_SELF."?install.{$plug['plugin_id']}\" title='".EPL_ADLAN_0."' >".ADMIN_INSTALLPLUGIN_ICON."</a>"; } } else { if ($plug_vars['menuName']) { $text .= EPL_NOINSTALL.str_replace("..", "", e_PLUGIN.$plug['plugin_path'])."/ ".EPL_DIRECTORY; } else { $text .= EPL_NOINSTALL_1.str_replace("..", "", e_PLUGIN.$plug['plugin_path'])."/ ".EPL_DIRECTORY; if($plug['plugin_installflag'] == false) { e107::getDb()->db_Delete('plugin', "plugin_installflag=0 AND (plugin_path='{$plug['plugin_path']}' OR plugin_path='{$plug['plugin_path']}/' ) "); } } } if ($plug['plugin_version'] != $plug_vars['@attributes']['version'] && $plug['plugin_installflag']) { // $text .= "<br /><input type='button' class='btn' onclick=\"location.href='".e_SELF."?upgrade.{$plug['plugin_id']}'\" title='".EPL_UPGRADE." to v".$plug_vars['@attributes']['version']."' value='".EPL_UPGRADE."' />"; $text .= "<a class='btn' href='".e_SELF."?upgrade.{$plug['plugin_id']}' title=\"".EPL_UPGRADE." to v".$plug_vars['@attributes']['version']."\" >".ADMIN_UPGRADEPLUGIN_ICON."</a>"; } $text .="</div></td>"; // $text .= "</tr>"; */ } } return $text; }
* @subpackage chatbox */ error_reporting(E_ALL); if (isset($_POST['chatbox_ajax'])) { define('e_MINIMAL', true); if (!defined('e107_INIT')) { require_once '../../class2.php'; } } global $e107cache, $e_event, $e107; $tp = e107::getParser(); $pref = e107::getPref(); if (!e107::isInstalled('chatbox_menu')) { return ''; } e107::lan('chatbox_menu', e_LANGUAGE); // FIXME - start - LAN is not loaded /* if(($pref['cb_layer']==2) || isset($_POST['chatbox_ajax'])) { if(isset($_POST['chat_submit'])) { //Normally the menu.sc file will auto-load the language file, this is needed in case //ajax is turned on and the menu is not loaded from the menu.sc inclXXXude_lan(e_PLUGIN.'chatbox_menu/languages/'.e_LANGUAGE.'/'.e_LANGUAGE.'.php'); } } // FIXME - end */
<?php /* * AnteUp - A Donation Tracking Plugin for e107 * * Copyright (C) 2012-2015 Patrick Weaver (http://trickmod.com/) * For additional information refer to the README.mkd file. * */ require_once "../../class2.php"; require_once HEADERF; require_once e_PLUGIN . "anteup/_class.php"; e107::lan('anteup'); $pref = e107::pref('anteup'); if (!empty($pref['anteup_paypal']) || $pref['anteup_paypal'] != "*****@*****.**") { $frm = e107::getForm(); $tp = e107::getParser(); $sc = e107::getScBatch('anteup', true); $template = e107::getTemplate('anteup'); $text = $frm->open('donate_form', 'post', 'https://www.paypal.com/cgi-bin/webscr'); $text .= $tp->parseTemplate($template['donate'], false, $sc); $text .= $frm->hidden('cmd', '_xclick'); $text .= $frm->hidden('business', $pref['anteup_paypal']); $text .= $frm->hidden('notify_url', ANTEUP_ABS . 'ipn.php'); $text .= $frm->hidden('return', ANTEUP_ABS . 'return.php?thanks'); $text .= $frm->hidden('cancel_return', ANTEUP_ABS . 'return.php?cancel'); $text .= $frm->close(); } else { $text = "<div class='center'>" . LAN_ANTEUP_DONATE_04 . "</div>"; } e107::getRender()->tablerender(LAN_ANTEUP_DONATE_TITLE, $text);
* * Forum main page * */ if (!defined('e107_INIT')) { require_once '../../class2.php'; } $e107 = e107::getInstance(); $tp = e107::getParser(); $sql = e107::getDb(); if (!$e107->isInstalled('forum')) { // FIXME GLOBAL - get rid of all e_BASE|e_HTTP|Whatever/index.php - just point to SITEURL header('Location: ' . SITEURL); exit; } e107::lan('forum', "front", true); // include_lan(e_PLUGIN.'forum/languages/'.e_LANGUAGE.'/lan_forum.php'); // using English_front.php now require_once e_PLUGIN . 'forum/forum_class.php'; $forum = new e107forum(); if ($untrackId = varset($_REQUEST['untrack'])) { $forum->track('del', USERID, $untrackId); header('location:' . $e107->url->create('forum/thread/track', array(), 'full=1&encode=0')); exit; } if (isset($_GET['f'])) { if (isset($_GET['id'])) { $id = (int) $_GET['id']; } switch ($_GET['f']) { case 'mfar': $forum->forumMarkAsRead($id);
<?php if (!defined('e107_INIT')) { exit; } e107::lan('core', 'contact'); $head = '<form id="contact-menu" action="' . e_HTTP . 'contact.php" method="post" >'; //XXX Template must conform to Bootstrap specs: http://twitter.github.com/bootstrap/base-css.html#forms //TODO Security Image. $foot = '</form>'; $template = e107::getCoreTemplate('contact', 'menu'); $contact_shortcodes = e107::getScBatch('contact'); $text = $tp->parseTemplate($head . $template . $foot, true, $contact_shortcodes); $ns->tablerender("Contact Us", $text, 'contact-menu');
/** * Send an activation email to all unactivated users older than so many hours. * @param bool $resetPasswords * @param int $age in hours. ie. older than 24 hours will be sent an email. */ function resend_to_all($resetPasswords = false, $age = 24, $class = '') { global $sql, $pref; $tp = e107::getParser(); $sql = e107::getDb(); $sql2 = e107::getDb('toall'); $emailLogin = e107::getPref('allowEmailLogin'); e107::lan('core', 'signup'); $ageOpt = intval($age) . " hours ago"; $age = strtotime($ageOpt); // $query = "SELECT u.*, ue.* FROM `#user` AS u LEFT JOIN `#user_extended` AS ue ON ue.user_extended_id = u.user_id WHERE u.user_ban = 2 AND u.user_email != '' AND u.user_join < ".$age." ORDER BY u.user_id DESC"; $query = "SELECT u.* FROM `#user` AS u WHERE u.user_ban = 2 AND u.user_email != '' AND u.user_join < " . $age . " "; if (!empty($class)) { $query .= " AND FIND_IN_SET( " . intval($class) . ", u.user_class) "; } $query .= " ORDER BY u.user_id DESC"; $sql->gen($query); $recipients = array(); $usr = e107::getUserSession(); while ($row = $sql->fetch()) { if ($resetPasswords === true) { $rawPassword = $usr->generateRandomString('********'); $sessKey = e_user_model::randomKey(); $updateQry = array('user_sess' => $sessKey, 'user_password' => $usr->HashPassword($rawPassword, $row['user_loginname']), 'WHERE' => 'user_id = ' . $row['user_id'] . " LIMIT 1"); if (!$sql2->update('user', $updateQry)) { e107::getMessage()->addError("Error updating user's password. #" . $row['user_id'] . " : " . $row['user_email']); e107::getMessage()->addDebug(print_a($updateQry, true)); // break; } else { e107::getMessage()->addInfo("Updated " . $row['user_id'] . " : " . $row['user_email']); } $row['user_sess'] = $sessKey; } else { $rawPassword = '******'; } $activationUrl = SITEURL . "signup.php?activate." . $row['user_id'] . "." . $row['user_sess']; $recipients[] = array('mail_recipient_id' => $row['user_id'], 'mail_recipient_name' => $row['user_name'], 'mail_recipient_email' => $row['user_email'], 'mail_target_info' => array('USERID' => $row['user_id'], 'LOGINNAME' => intval($emailLogin) === 1 ? $row['user_email'] : $row['user_loginname'], 'PASSWORD' => $rawPassword, 'DISPLAYNAME' => $tp->toDB($row['user_name']), 'SUBJECT' => LAN_SIGNUP_98, 'USERNAME' => $row['user_name'], 'USERLASTVISIT' => $row['user_lastvisit'], 'ACTIVATION_LINK' => '<a href="' . $activationUrl . '">' . $activationUrl . '</a>', 'ACTIVATION_URL' => $activationUrl, 'DATE_SHORT' => $tp->toDate(time(), 'short'), 'DATE_LONG' => $tp->toDate(time(), 'long'), 'SITEURL' => SITEURL)); // echo $row['user_id']." ".$row['user_sess']." ".$row['user_name']." ".$row['user_email']."<br />"; } $siteadminemail = e107::getPref('siteadminemail'); $siteadmin = e107::getPref('siteadmin'); $mailer = e107::getBulkEmail(); // Create the mail body $mailData = array('mail_total_count' => count($recipients), 'mail_content_status' => MAIL_STATUS_TEMP, 'mail_create_app' => 'core', 'mail_title' => 'RESEND ACTIVATION', 'mail_subject' => LAN_SIGNUP_98, 'mail_sender_email' => e107::getPref('replyto_email', $siteadminemail), 'mail_sender_name' => e107::getPref('replyto_name', $siteadmin), 'mail_notify_complete' => 0, 'mail_body' => 'null', 'template' => 'signup', 'mail_send_style' => 'signup'); $mailer->sendEmails('signup', $mailData, $recipients, array('mail_force_queue' => 1)); $totalMails = count($recipients); $url = e_ADMIN . "mailout.php?mode=pending&action=list"; e107::getMessage()->addSuccess("Total emails added to <a href='" . $url . "'>mail queue</a>: " . $totalMails); }
/** * Go online * @param boolean $online_tracking * @param boolean $flood_control * @return void */ public function goOnline($online_tracking = false, $flood_control = false) { // global $pref, $e_event; // Not needed as globals //global $online_timeout, $online_warncount, $online_bancount; // Not needed as globals //global $members_online, $total_online; // Not needed as globals global $listuserson; // FIXME - remove it, make it property, call e_online signleton - e107::getOnline() $e107 = e107::getInstance(); $sql = e107::getDb(); $user = e107::getUser(); if ($online_tracking || $flood_control) { $online_timeout = 300; list($ban_access_guest, $ban_access_member) = explode(',', e107::getPref('ban_max_online_access', '100,200')); $online_bancount = max($ban_access_guest, 50); // Safety net for incorrect values if ($user->isUser()) { $online_bancount = max($online_bancount, $ban_access_member); } $online_warncount = $online_bancount * 0.9; // Set warning threshold at 90% of ban threshold //TODO Add support for all queries. // $page = (strpos(e_SELF, 'forum_') !== FALSE) ? e_SELF.'.'.e_QUERY : e_SELF; // $page = (strpos(e_SELF, 'comment') !== FALSE) ? e_SELF.'.'.e_QUERY : $page; // $page = (strpos(e_SELF, 'content') !== FALSE) ? e_SELF.'.'.e_QUERY : $page; $page = e_REQUEST_URI; // mod rewrite & single entry support // FIXME parse url, trigger registered e_online callbacks $page = e107::getParser()->toDB($page, true); /// @todo - try not to use toDB() - triggers prefilter $ip = e107::getIPHandler()->getIP(FALSE); $udata = $user->isUser() && USER ? $user->getId() . '.' . $user->getName() : '0'; // USER check required to make sure they logged in without an error. $agent = $_SERVER['HTTP_USER_AGENT']; // XXX - more exceptions, e.g. hide online location for admins/users (pref), e_jlsib.php, etc // XXX - more advanced flod timing when e_AJAX_REQUEST, e.g. $ban_access_ajax = 300 $update_page = deftrue('e_AJAX_REQUEST') ? '' : ", online_location='{$page}'"; $insert_query = array('online_timestamp' => time(), 'online_flag' => 0, 'online_user_id' => $udata, 'online_ip' => $ip, 'online_location' => $page, 'online_pagecount' => 1, 'online_active' => 0, 'online_agent' => $agent, 'online_language' => e_LAN); // !deftrue('e_AJAX_REQUEST') // TODO add option to hide users from online list? boolean online_hide field? // don't do anything if main admin logged in as another user if ($user->isUser() && !$user->getParentId()) { // Find record that matches IP or visitor, or matches user info if ($sql->select('online', '*', "(`online_ip` = '{$ip}' AND `online_user_id` = '0') OR `online_user_id` = '{$udata}'")) { $row = $sql->fetch(); if ($row['online_user_id'] == $udata) { //Matching user record if ($row['online_timestamp'] < time() - $online_timeout) { //It has been at least 'online_timeout' seconds since this user's info last logged //Update user record with timestamp, current IP, current page and set pagecount to 1 $query = "online_timestamp='" . time() . "', online_ip='{$ip}'{$update_page}, online_pagecount=1, `online_active` = 1 WHERE online_user_id='{$row['online_user_id']}'"; } else { if (!$user->isAdmin()) { $row['online_pagecount']++; } // Update user record with current IP, current page and increment pagecount $query = "online_ip='{$ip}'{$update_page}, `online_pagecount` = '" . intval($row['online_pagecount']) . "', `online_active` = 1 WHERE `online_user_id` = '{$row['online_user_id']}'"; } } else { //Found matching visitor record (ip only) for this user if ($row['online_timestamp'] < time() - $online_timeout) { // It has been at least 'timeout' seconds since this user has connected // Update record with timestamp, current IP, current page and set pagecount to 1 $query = "`online_timestamp` = '" . time() . "', `online_user_id` = '{$udata}'{$update_page}, `online_pagecount` = 1, `online_active` = 1 WHERE `online_ip` = '{$ip}' AND `online_user_id` = '0'"; } else { // Another visit within the timeout period if (!$user->isAdmin()) { $row['online_pagecount']++; } //Update record with current IP, current page and increment pagecount $query = "`online_user_id` = '{$udata}'{$update_page}, `online_pagecount` = " . intval($row['online_pagecount']) . ", `online_active` =1 WHERE `online_ip` = '{$ip}' AND `online_user_id` = '0'"; } } $sql->update('online', $query); } else { $sql->insert('online', $insert_query); } } elseif (!$user->getParentId()) { //Current page request is from a guest if ($sql->select('online', '*', "`online_ip` = '{$ip}' AND `online_user_id` = '0'")) { // Recent visitor $row = $sql->fetch(); if ($row['online_timestamp'] < time() - $online_timeout) { //Update record with timestamp, current page, and set pagecount to 1 $query = "`online_timestamp` = '" . time() . "'{$update_page}, `online_pagecount` = 1 WHERE `online_ip` = '{$ip}' AND `online_user_id` = '0'"; } else { //Update record with current page and increment pagecount $row['online_pagecount']++; // echo "here {$online_pagecount}"; $query = "`online_pagecount` = {$row['online_pagecount']}{$update_page} WHERE `online_ip` = '{$ip}' AND `online_user_id` = '0'"; } $sql->update('online', $query); } else { // New visitor $sql->insert('online', $insert_query); } } if ($user->isAdmin() || e107::getPref('autoban') != 1 && e107::getPref('autoban') != 2 || !isset($row['online_pagecount'])) { $row['online_pagecount'] = 1; } // Always allow localhost - any problems are usually semi-intentional! if (varset($row['online_ip']) != '127.0.0.1' && varset($row['online_ip']) != e107::LOCALHOST_IP && varset($row['online_ip']) != e107::LOCALHOST_IP2) { // Check for excessive access if ($row['online_pagecount'] > $online_bancount) { e107::lan('core', 'banlist', true); //e_LANGUAGEDIR.e_LANGUAGE.'/admin/lan_banlist.php' $reason = e107::getParser()->lanVars(BANLAN_78, $row['online_pagecount']); // str_replace('--HITS--',$row['online_pagecount'], BANLAN_78) if (true === e107::getIPHandler()->add_ban(2, $reason, $ip, 0)) { e107::getEvent()->trigger('flood', $ip); //BC e107::getEvent()->trigger('user_ban_flood', $ip); exit; } } elseif ($row['online_pagecount'] >= $online_warncount) { echo "<div style='text-align:center; font: 11px verdana, tahoma, arial, helvetica, sans-serif;'><b>" . LAN_WARNING . "</b><br /><br />" . CORE_LAN6 . "<br /></div>"; exit; } } // Delete records for users (and guests) not seen for a while // FIXME - DB optimization - mark records as deleted (online_deleted=1), delete once per hour (could be pref) via e_cron // FIXME - Additional prefs for this (it does 2-3 more queries no matter someone need them), could be also separate method // Speed up ajax requests if (!deftrue('e_AJAX_REQUEST')) { $sql->delete('online', '`online_timestamp` < ' . (time() - $online_timeout)); // FIXME - don't use constants below, save data in class vars, call e_online signleton - e107::getOnline() // $total_online = $sql->db_Count('online'); // 1 less query! :-) if ($total_online = $sql->gen('SELECT o.*,u.user_image FROM #online AS o LEFT JOIN #user AS u ON o.online_user_id = u.user_id WHERE o.online_pagecount > 0 ORDER BY o.online_timestamp DESC')) { $member_list = ''; $members_online = 0; $listuserson = array(); while ($row = $sql->fetch()) { $row['online_bot'] = $this->isBot($row['online_agent']); // Sort into usable format and add bot field. $user = array('user_location' => $row['online_location'], 'user_bot' => $this->isBot($row['online_agent']), 'user_agent' => $row['online_agent'], 'user_ip' => $row['online_ip'], 'user_currentvisit' => $row['online_timestamp'], 'user_online' => $row['online_flag'], 'user_pagecount' => $row['online_pagecount'], 'user_active' => $row['online_active'], 'user_image' => vartrue($row['user_image'], false), 'online_user_id' => $row['online_user_id'], 'user_language' => $row['online_language']); if ($row['online_user_id'] != 0) { $vals = explode('.', $row['online_user_id'], 2); $user['user_id'] = $vals[0]; $user['user_name'] = $vals[1]; $member_list .= "<a href='" . SITEURL . "user.php?id.{$vals[0]}'>{$vals[1]}</a> "; $listuserson[$row['online_user_id']] = $row['online_location']; $this->users[] = $user; $members_online++; } else { $user['user_id'] = 0; $user['user_name'] = 'guest'; // Maybe should just be an empty string? $this->guests[] = $user; } } } define('TOTAL_ONLINE', $total_online); define('MEMBERS_ONLINE', $members_online); define('GUESTS_ONLINE', $total_online - $members_online); define('ON_PAGE', $sql->db_Count('online', '(*)', "WHERE `online_location` = '{$page}' ")); define('MEMBER_LIST', $member_list); //update most ever online $olCountPrefs = e107::getConfig('history'); // Get historic counts of members on line $olCountPrefs->setParam('nologs', true); if ($total_online > $olCountPrefs->get('most_members_online') + $olCountPrefs->get('most_guests_online')) { $olCountPrefs->set('most_members_online', MEMBERS_ONLINE); $olCountPrefs->set('most_guests_online', GUESTS_ONLINE); $olCountPrefs->set('most_online_datestamp', time()); $olCountPrefs->save(false, true, false); } } } else { define('e_TRACKING_DISABLED', true); // Used in forum, online menu define('TOTAL_ONLINE', ''); define('MEMBERS_ONLINE', ''); define('GUESTS_ONLINE', ''); define('ON_PAGE', ''); define('MEMBER_LIST', ''); } }
WordPress (users) Mambo/Joomla PHPBB2 PHPBB3 SMF PHPNuke proboards PHPFusion */ define('IMPORT_DEBUG', TRUE); // define('IMPORT_DEBUG',TRUE); require_once "../../class2.php"; // define("USE_PERSISTANT_DB",TRUE); $frm = e107::getForm(); $mes = e107::getMessage(); e107::lan('import', true, true); //XXX A Fresh Start class import_admin extends e_admin_dispatcher { protected $modes = array('main' => array('controller' => 'import_main_ui', 'path' => null, 'ui' => 'import_admin_form_ui', 'uipath' => null), 'cat' => array('controller' => 'import_cat_ui', 'path' => null, 'ui' => 'import_cat_form_ui', 'uipath' => null)); protected $adminMenu = array('main/list' => array('caption' => LAN_LIST, 'perm' => '0')); protected $adminMenuAliases = array('main/edit' => 'main/list'); protected $menuTitle = LAN_PLUGIN_IMPORT_NAME; } class import_main_ui extends e_admin_ui { protected $pluginTitle = LAN_PLUGIN_IMPORT_NAME; protected $pluginName = 'import'; protected $table = false; protected $providers = array(); // the different types of import.
<?php /** * e107 Links Page plugin * * @package e107_plugins * @subpackage links_page * @version $Id$; */ if (!defined('e107_INIT')) { exit; } e107::lan('links_page', true, true); class links_page_dashboard { function chart() { return false; } function status() { $db = e107::getDb(); $alllinks = $db->count("links_page", "(*)", "WHERE link_active != 0 "); $var[0]['icon'] = "<img src='" . e_PLUGIN_ABS . "links_page/images/linkspage_16.png' style='width: 16px; height: 16px; vertical-align: bottom' alt='' /> "; $var[0]['title'] = LAN_LINKS_1; $var[0]['url'] = e_PLUGIN . "links_page/admin_config.php?mode=main&action=list"; $var[0]['total'] = $alllinks; $allcatlinks = $db->count("links_page_cat"); $var[1]['icon'] = "<img src='" . e_PLUGIN_ABS . "links_page/images/linkspage_16.png' style='width: 16px; height: 16px; vertical-align: bottom' alt='' /> "; $var[1]['title'] = LCLAN_CAT_12; $var[1]['url'] = e_PLUGIN . "links_page/admin_config.php?mode=cat&action=list";
/* * e107 website system * * Copyright (C) 2008-2014 e107 Inc (e107.org) * Released under the terms and conditions of the * GNU General Public License (http://www.gnu.org/licenses/gpl.txt) * */ $eplug_admin = true; require_once '../../class2.php'; if (!getperms('P')) { e107::redirect('admin'); exit; } e107::lan('forum', 'admin'); e107::lan('forum', 'front', true); //e107::includeLan(e_PLUGIN.'forum/languages/'.e_LANGUAGE.'/English_admin.php'); //e107::lan('forum','', 'front'); $legacy = false; if (E107_DEBUG_LEVEL > 0 && $legacy == true) { define('OLD_FORUMADMIN', true); //e107::getMessage()->addwarning("Experimental code now active. Using this page in debug mode active could break your forum configuration."); } // Generated e107 Plugin Admin Area if (!deftrue('OLD_FORUMADMIN')) { class forum_admin extends e_admin_dispatcher { protected $modes = array('main' => array('controller' => 'forum_ui', 'path' => null, 'ui' => 'forum_form_ui', 'uipath' => null), 'mods' => array('controller' => 'forum_ui', 'path' => null, 'ui' => 'forum_form_ui', 'uipath' => null), 'report' => array('controller' => 'reported_ui', 'path' => null, 'ui' => 'reported_form_ui', 'uipath' => null), 'post' => array('controller' => 'post_ui', 'path' => null, 'ui' => 'post_form_ui', 'uipath' => null)); protected $adminMenu = array('main/list' => array('caption' => LAN_MANAGE, 'perm' => 'P'), 'main/create' => array('caption' => LAN_CREATE, 'perm' => 'P'), 'opt1' => array('divider' => true), 'main/rules' => array('caption' => WMGLAN_5, 'perm' => 'P'), 'mods/list' => array('caption' => LAN_FORUM_2003, 'perm' => 'P'), 'main/prefs' => array('caption' => LAN_PREFS, 'perm' => 'P'), 'opt2' => array('divider' => true), 'report/list' => array('caption' => FORLAN_116, 'perm' => 'P'), 'post/list' => array('caption' => "Latest Posts", 'perm' => 'P'), 'main/prune' => array('caption' => LAN_PRUNE, 'perm' => 'P'), 'main/tools' => array('caption' => FORLAN_153, 'perm' => 'p')); protected $adminMenuAliases = array('main/edit' => 'main/list'); protected $menuTitle = 'Forum';