diff --git a/class2.php b/class2.php index 60f40f1ee..665091551 100755 --- a/class2.php +++ b/class2.php @@ -1200,8 +1200,12 @@ function check_email($email) * @param int $uid * @return bool */ -function check_class($var, $userclass = USERCLASS_LIST, $uid = 0) +function check_class($var, $userclass = null, $uid = 0) { + if ($userclass === null) + { + $userclass = defset('USERCLASS_LIST', '0'); + } $e107 = e107::getInstance(); if ($var === e_LANGUAGE) { diff --git a/e107_plugins/download/includes/admin.php b/e107_plugins/download/includes/admin.php index f088c3468..0501be4c1 100644 --- a/e107_plugins/download/includes/admin.php +++ b/e107_plugins/download/includes/admin.php @@ -1818,7 +1818,7 @@ $columnInfo = array( // See if any mirrors defined // Need to check all the possible mirror names - might have deleted the first one if we're in edit mode - if(count($_POST['download_mirror_name'])) + if(is_array($_POST['download_mirror_name'])) { foreach ($_POST['download_mirror_name'] as $mn) { diff --git a/e107_plugins/forum/e_dashboard.php b/e107_plugins/forum/e_dashboard.php index 233b08f29..3ea4beaaa 100644 --- a/e107_plugins/forum/e_dashboard.php +++ b/e107_plugins/forum/e_dashboard.php @@ -16,8 +16,8 @@ class forum_dashboard // include plugin-folder in the name. $sql = e107::getDb(); $forum_posts = $sql->count('forum_post'); - $var[0]['icon'] = E_16_FORUM; - $var[0]['title'] = LAN_PLUGIN_FORUM_POSTS; + $var[0]['icon'] = defset('E_16_FORUM'); + $var[0]['title'] = defset('LAN_PLUGIN_FORUM_POSTS'); $var[0]['url'] = e_PLUGIN."forum/forum_admin.php"; $var[0]['total'] = $forum_posts; @@ -30,8 +30,8 @@ class forum_dashboard // include plugin-folder in the name. $sql = e107::getDb(); $reported_posts = $sql->count('generic', '(*)', "WHERE gen_type='reported_post' OR gen_type='Reported Forum Post'"); - $var[0]['icon'] = E_16_FORUM; - $var[0]['title'] = ADLAN_LAT_6; + $var[0]['icon'] = defset('E_16_FORUM'); + $var[0]['title'] = defset('ADLAN_LAT_6'); $var[0]['url'] = e_PLUGIN."forum/forum_admin.php?mode=report&action=list"; $var[0]['total'] = $reported_posts; diff --git a/e107_plugins/forum/forum_admin.php b/e107_plugins/forum/forum_admin.php index 9776dc70e..2d406494c 100644 --- a/e107_plugins/forum/forum_admin.php +++ b/e107_plugins/forum/forum_admin.php @@ -17,6 +17,7 @@ if (!getperms('P')) } +e107::lan('forum', 'global', true); e107::lan('forum', 'admin', true); e107::lan('forum', 'front', true); diff --git a/e107_plugins/forum/forum_stats.php b/e107_plugins/forum/forum_stats.php index c8c167b9a..5b2401dbb 100644 --- a/e107_plugins/forum/forum_stats.php +++ b/e107_plugins/forum/forum_stats.php @@ -460,7 +460,7 @@ class forumStats $frm = e107::getForm(); $breadarray = array( - array('text'=> e107::pref('forum','title', LAN_PLUGIN_FORUM_NAME), 'url' => e107::url('forum','index') ), + array('text'=> e107::pref('forum','title', defset('LAN_PLUGIN_FORUM_NAME')), 'url' => e107::url('forum','index') ), array('text'=>LAN_FORUM_6013, 'url'=>null) ); diff --git a/e107_plugins/forum/templates/forum_preview_template.php b/e107_plugins/forum/templates/forum_preview_template.php index b5a10e73e..8a86aa4db 100644 --- a/e107_plugins/forum/templates/forum_preview_template.php +++ b/e107_plugins/forum/templates/forum_preview_template.php @@ -12,7 +12,7 @@ if (!defined('e107_INIT')) { exit; } if(!defined("USER_WIDTH") && !deftrue('BOOTSTRAP')){ define("USER_WIDTH","width:95%;margin-left:auto;margin-right:auto"); } $FORUM_PREVIEW = "
".LAN_FORUM_3005. ($action != "nt" ? " | " : " ( ".LAN_FORUM_3011.": {PREVIEW_SUBJECT} )")." diff --git a/e107_plugins/user/usertheme_menu_config.php b/e107_plugins/user/usertheme_menu_config.php index bbc499c39..124988ed8 100644 --- a/e107_plugins/user/usertheme_menu_config.php +++ b/e107_plugins/user/usertheme_menu_config.php @@ -61,7 +61,7 @@ if (isset($_POST['update_theme'])) $cfg->set('allow_theme_select', $themeeditclass); $cfg->save(true,true,true); - $woffle = LAN_UMENU_THEME_8.$pref['allowed_themes'].'[!br!]'.LAN_UMENU_THEME_9.$pref['allow_theme_select']; + $woffle = defset('LAN_UMENU_THEME_8').$pref['allowed_themes'].'[!br!]'.defset('LAN_UMENU_THEME_9').$pref['allow_theme_select']; e107::getLog()->add('UTHEME_01',$woffle,E_LOG_INFORMATIVE,''); } } @@ -79,7 +79,7 @@ $themeeditclass = varset($pref['allow_theme_select'],e_UC_NOBODY); $text = "