diff --git a/e107_plugins/forum/forum_post.php b/e107_plugins/forum/forum_post.php index 773a90dfa..dd9f7309f 100644 --- a/e107_plugins/forum/forum_post.php +++ b/e107_plugins/forum/forum_post.php @@ -9,15 +9,14 @@ * Forum Posting * * $Source: /cvs_backup/e107_0.8/e107_plugins/forum/forum_post.php,v $ - * $Revision: 1.40 $ - * $Date: 2009-11-18 01:05:36 $ - * $Author: e107coders $ + * $Revision: 1.41 $ + * $Date: 2009-11-19 09:52:35 $ + * $Author: marj_nl_fr $ */ require_once('../../class2.php'); -$lan_file = e_PLUGIN.'forum/languages/'.e_LANGUAGE.'/lan_forum_post.php'; -include(file_exists($lan_file) ? $lan_file : e_PLUGIN.'forum/languages/English/lan_forum_post.php'); +include_lan(e_PLUGIN.'forum/languages/'.e_LANGUAGE.'/lan_forum_post.php'); if (isset($_POST['fjsubmit'])) { diff --git a/e107_plugins/forum/forum_uploads.php b/e107_plugins/forum/forum_uploads.php index fdd602bb7..1e6584570 100644 --- a/e107_plugins/forum/forum_uploads.php +++ b/e107_plugins/forum/forum_uploads.php @@ -9,9 +9,9 @@ * * * $Source: /cvs_backup/e107_0.8/e107_plugins/forum/forum_uploads.php,v $ - * $Revision: 1.5 $ - * $Date: 2009-11-18 01:05:36 $ - * $Author: e107coders $ + * $Revision: 1.6 $ + * $Date: 2009-11-19 09:52:35 $ + * $Author: marj_nl_fr $ */ require_once("../../class2.php"); @@ -21,8 +21,7 @@ if(!USER) header("location:".e_BASE.$PLUGINS_DIRECTORY."forum/forum.php"); exit; } -$lan_file = e_PLUGIN.'forum/languages/'.e_LANGUAGE.'/lan_forum_uploads.php'; -include_once(file_exists($lan_file) ? $lan_file : e_PLUGIN.'forum/languages/English/lan_forum_uploads.php'); +include_lan(e_PLUGIN.'forum/languages/'.e_LANGUAGE.'/lan_forum_uploads.php'); if(is_array($_POST['delete'])) { diff --git a/e107_plugins/forum/newforumposts_menu_config.php b/e107_plugins/forum/newforumposts_menu_config.php index ea079eb78..52ae22050 100755 --- a/e107_plugins/forum/newforumposts_menu_config.php +++ b/e107_plugins/forum/newforumposts_menu_config.php @@ -9,22 +9,22 @@ * * * $Source: /cvs_backup/e107_0.8/e107_plugins/forum/newforumposts_menu_config.php,v $ - * $Revision: 1.4 $ - * $Date: 2009-11-18 01:05:36 $ - * $Author: e107coders $ + * $Revision: 1.5 $ + * $Date: 2009-11-19 09:52:35 $ + * $Author: marj_nl_fr $ */ $eplug_admin = TRUE; -require_once("../../class2.php"); -if (!getperms("1")) { - header("location:".e_BASE."index.php"); - exit ; +require_once('../../class2.php'); +if (!getperms('1')) +{ + header('location:'.e_BASE.'index.php'); + exit(); } -require_once(e_ADMIN."auth.php"); - -$lan_file = e_PLUGIN."forum/languages/".e_LANGUAGE."/lan_newforumposts_menu.php"; -require_once(file_exists($lan_file) ? $lan_file : e_PLUGIN."forum/languages/English/lan_newforumposts_menu.php"); +require_once(e_ADMIN.'auth.php'); +include_lan(e_PLUGIN.'forum/languages/'.e_LANGUAGE.'/lan_newforumposts_menu.php'); + if (isset($_POST['update_menu'])) { while (list($key, $value) = each($_POST)) { if ($value != NFP_9) { diff --git a/e107_plugins/newforumposts_main/admin_config.php b/e107_plugins/newforumposts_main/admin_config.php index 0e578c47a..84c292b17 100644 --- a/e107_plugins/newforumposts_main/admin_config.php +++ b/e107_plugins/newforumposts_main/admin_config.php @@ -1,4 +1,4 @@ -tablerender("", "
$message
"); } - - - + + $text = "
"; - + "; + + $NEWFORUMPOSTSTYLE_FOOTER = " + + + ".NFPM_LAN_6.": {TOTAL_TOPICS} | ".NFPM_LAN_4.": {TOTAL_REPLIES} | ".NFPM_LAN_3.": {TOTAL_VIEWS} + + + + "; + } $results = $sql->db_Select_gen(" @@ -69,17 +78,18 @@ ORDER BY t.$query DESC LIMIT 0, ".$pref['nfp_amount']); $forumArray = $sql->db_getList(); -if (!isset($gen) || !is_object($gen)) { +if(!isset($gen) || !is_object($gen)) +{ $gen = new convert; } -if (file_exists(THEME."forum/new_small.png")) +if(is_readable(THEME."forum/new_small.png")) { - $ICON = ""; + $ICON = ""; } else { - $ICON = ""; + $ICON = ""; } $TOTAL_TOPICS = $sql->db_Count("forum_t", "(*)", " WHERE thread_parent='0' "); $TOTAL_REPLIES = $sql->db_Count("forum_t", "(*)", " WHERE thread_parent!='0' "); @@ -88,10 +98,10 @@ $tmp = $sql->db_Fetch(); $TOTAL_VIEWS = $tmp[0]; $text = preg_replace("/\{(.*?)\}/e", '$\1', $NEWFORUMPOSTSTYLE_HEADER); -foreach($forumArray as $forumInfo) +foreach ($forumArray as $forumInfo) { extract($forumInfo); - + $r_datestamp = $gen->convert_date($thread_lastpost, "forum"); if($thread_total_replies) { @@ -118,7 +128,7 @@ foreach($forumArray as $forumInfo) $LASTPOST = " - "; $LASTPOSTDATE = ""; } - + $x = explode(chr(1), $thread_user); $tmp = explode(".", $x[0], 2); if($user_name) @@ -136,22 +146,21 @@ foreach($forumArray as $forumInfo) $POSTER = NFPM_L16; } } - + $THREAD = "$thread_name"; $FORUM = "$forum_name"; - + $VIEWS = $thread_views; $REPLIES = $thread_total_replies; $text .= preg_replace("/\{(.*?)\}/e", '$\1', $NEWFORUMPOSTSTYLE_MAIN); - + } $text .= preg_replace("/\{(.*?)\}/e", '$\1', $NEWFORUMPOSTSTYLE_FOOTER); $text = ($pref['nfp_layer'] ? "
".$text."
" : $text); -if ($results) +if($results) { - $ns->tablerender($pref['nfp_caption'], $text, "nfp"); + $ns->tablerender($pref["nfp_caption"], $text, "nfp"); } -?>