diff --git a/e107_admin/banlist.php b/e107_admin/banlist.php index 343c1ef9c..0f1d3eb3b 100644 --- a/e107_admin/banlist.php +++ b/e107_admin/banlist.php @@ -771,7 +771,7 @@ class banlist_form_ui extends e_admin_form_ui - return $this->selectbox('banlist_bantype',$ipAdministrator->banTypes, $curVal); + return $this->select('banlist_bantype',$ipAdministrator->banTypes, $curVal); break; case 'filter': @@ -817,7 +817,7 @@ class banlist_form_ui extends e_admin_form_ui $opts[$curVal] = e107::getParser()->toDate($curVal, 'short'); } - return $this->selectbox('banlist_banexpires',$opts, $curVal); + return $this->select('banlist_banexpires',$opts, $curVal); // return $frm->text('banlist_banexpires',$curVal); break; diff --git a/e107_admin/cache.php b/e107_admin/cache.php index 6925096fa..896b19ee1 100644 --- a/e107_admin/cache.php +++ b/e107_admin/cache.php @@ -50,7 +50,7 @@ if (isset($_POST['submit_cache'])) if (isset($_POST['trigger_empty_cache'])) { - e107::getLog()->logSuccess(CACLAN_6); + e107::getLog()->addSuccess(CACLAN_6); switch ($_POST['option_clear_cache']) { case 'empty_contentcache': diff --git a/e107_admin/db.php b/e107_admin/db.php index bfdbb44bd..c1cabf781 100644 --- a/e107_admin/db.php +++ b/e107_admin/db.php @@ -22,7 +22,7 @@ if(!getperms('0')) if(isset($_POST['back'])) { - header("location: ".e_SELF); + e107::redirect(e_SELF); exit(); } diff --git a/e107_admin/emoticon.php b/e107_admin/emoticon.php index 2b119de82..6b6f6117b 100644 --- a/e107_admin/emoticon.php +++ b/e107_admin/emoticon.php @@ -29,8 +29,6 @@ require_once("auth.php"); $mes = e107::getMessage(); - - // Change the active emote pack if (isset($_POST['active'])) { @@ -38,7 +36,7 @@ if (isset($_POST['active'])) { $pref['smiley_activate'] = (int) $_POST['smiley_activate']; e107::getLog()->add($pref['smiley_activate'] ? 'EMOTE_02' : 'EMOTE_03', $pref['emotepack'], E_LOG_INFORMATIVE, ''); - e107::getConfig()->set('smiley_activate',$pref['smiley_activate'])->save(true,true,true); + e107::getConfig()->set('smiley_activate', $pref['smiley_activate'])->save(true, true, true); $update = true; } @@ -55,34 +53,34 @@ if (isset($_POST['active'])) $fl = e107::getFile(); $emote = new emotec; -$one_pack = FALSE; +$one_pack = false; $filtered = e107::getParser()->filter($_POST); // Check for pack-related buttons pressed -foreach($filtered as $key => $value) +foreach ($filtered as $key => $value) { - if(strpos($key, "subPack_") !== false) + if (strpos($key, "subPack_") !== false) { $subpack = str_replace("subPack_", "", $key); $emote->emoteConf($subpack); break; } - if(strpos($key, "XMLPack_") !== false) + if (strpos($key, "XMLPack_") !== false) { $subpack = str_replace("XMLPack_", "", $key); $emote->emoteXML($subpack); break; } - if(strpos($key, "defPack_") !== false) + if (strpos($key, "defPack_") !== false) { - e107::getConfig()->set('emotepack', str_replace("defPack_", "", $key))->save(true,true,true); + e107::getConfig()->set('emotepack', str_replace("defPack_", "", $key))->save(true, true, true); e107::getLog()->add('EMOTE_01', $pref['emotepack'], E_LOG_INFORMATIVE, ''); break; } - if(strpos($key, "scanPack_") !== false) + if (strpos($key, "scanPack_") !== false) { $one_pack = str_replace("scanPack_", "", $key); break; @@ -92,26 +90,27 @@ foreach($filtered as $key => $value) // $ns->tablerender($caption, $mes->render() . $text); $check = $emote->installCheck($one_pack); -if($check!==FALSE) +if ($check !== false) { - $emote -> listPacks(); + $emote->listPacks(); } - class emotec { - var $packArray; // Stores an array of all available emote packs (as subdirectory names) + + var $packArray; // Stores an array of all available emote packs (as subdirectory names) function __construct() { + /* constructor */ $fl = e107::getFile(); - $this -> packArray = $fl->get_dirs(e_IMAGE."emotes"); + $this->packArray = $fl->get_dirs(e_IMAGE . "emotes"); - if(isset($_POST['sub_conf'])) - { // Update stored pack configuration - $this -> saveConf(); + if (isset($_POST['sub_conf'])) + { // Update stored pack configuration + $this->saveConf(); } } @@ -119,24 +118,25 @@ class emotec // List available emote packs function listPacks() { + $pref = e107::getPref(); $frm = e107::getForm(); $fl = e107::getFile(); $ns = e107::getRender(); - $mes = e107::getMessage(); + $mes = e107::getMessage(); $text = "