|
From: OryNider <ory...@us...> - 2008-01-13 12:08:34
|
Update of /cvsroot/mxbb/core/admin In directory sc8-pr-cvs16.sourceforge.net:/tmp/cvs-serv31137 Modified Files: pagestart.php Added Files: admin_mx_preview.php Log Message: Stuff for the new AdminCP :) --- NEW FILE: admin_mx_preview.php --- <?php /** * * @package mxBB Portal Core * @version $Id: admin_mx_preview.php,v 1.1 2008/01/13 12:08:26 orynider Exp $ * @copyright (c) 2002-2006 mxBB Project Team * @license http://opensource.org/licenses/gpl-license.php GNU General Public License v2 * @link http://www.mxbb.net * */ if( !empty($setmodules) ) { return; $module['Administration']['Preview_portal'] = 'admin/' . basename(__FILE__) . '?mode=portal'; $module['Administration']['Preview_forum'] = 'admin/' . basename(__FILE__) . '?mode=forum'; return; } // // Security and Page header // define('IN_PORTAL', 1); $mx_root_path = './../'; $phpEx = substr(strrchr(__FILE__, '.'), 1); require('./pagestart.' . $phpEx); // // Set mode // if( isset( $HTTP_POST_VARS['mode'] ) || isset( $HTTP_GET_VARS['mode'] ) ) { $mode = ( isset( $HTTP_POST_VARS['mode']) ) ? $HTTP_POST_VARS['mode'] : $HTTP_GET_VARS['mode']; $mode = htmlspecialchars($mode); } else { $mode = ''; } $preview_action = ($mode == 'portal') ? mx_append_sid(PORTAL_URL . "index.$phpEx") : mx_append_sid(PHPBB_URL . "index.$phpEx"); $template->set_filenames(array( 'admin_preview' => 'admin/admin_mx_preview.tpl') ); $template->assign_vars(array( 'U_PHPBB_ROOT_PATH' => PHPBB_URL, 'U_PORTAL_ROOT_PATH' => PORTAL_URL, "U_PHPBB_INDEX" => mx_append_sid(PHPBB_URL . "index.$phpEx"), "U_PORTAL_INDEX" => mx_append_sid(PORTAL_URL . "index.$phpEx"), "L_PORTAL_INDEX" => $lang['Portal_index'], "L_PREVIEW_PORTAL" => $lang['Preview_portal'], "S_PREVIEW_ACTION" => $preview_action, "L_PREVIEW_FORUM" => $lang['Preview_forum']) ); $template->pparse('admin_preview'); include_once('page_footer_admin.' . $phpEx); ?> Index: pagestart.php =================================================================== RCS file: /cvsroot/mxbb/core/admin/pagestart.php,v retrieving revision 1.24 retrieving revision 1.25 diff -C2 -d -r1.24 -r1.25 *** pagestart.php 9 Sep 2007 16:48:16 -0000 1.24 --- pagestart.php 13 Jan 2008 12:08:25 -0000 1.25 *************** *** 35,38 **** --- 35,44 ---- $mx_user->init($user_ip, PAGE_INDEX); + if (PORTAL_BACKEND == 'phpbb3') + { + //$mx_user->setup('acp/common', false); //To do + include_once( $mx_user->lang_path . 'acp/common.'.$phpEx); + } + if ( !$userdata['session_logged_in'] ) { |