|
From: Jon O. <jon...@us...> - 2008-10-31 18:54:31
|
Update of /cvsroot/mxbb/core/includes/sessions/internal In directory 23jxhf1.ch3.sourceforge.com:/tmp/cvs-serv6117/internal Modified Files: bbcode.php core.php login.php Log Message: http://www.mx-publisher.com/phpBB2/viewtopic.php?p=65197#65197 Massive update. Index: login.php =================================================================== RCS file: /cvsroot/mxbb/core/includes/sessions/internal/login.php,v retrieving revision 1.7 retrieving revision 1.8 diff -C2 -d -r1.7 -r1.8 *** login.php 4 Oct 2008 07:04:25 -0000 1.7 --- login.php 31 Oct 2008 18:54:23 -0000 1.8 *************** *** 17,21 **** if ($mx_request_vars->is_request('login') && (!$userdata['session_logged_in'] || $mx_request_vars->is_post('admin')) ) { ! $username = $mx_request_vars->is_post('username') ? $phpBB2->phpbb_clean_username($mx_request_vars->post('username', MX_TYPE_NO_TAGS)) : ''; $password = $mx_request_vars->post('password', MX_TYPE_NO_TAGS); --- 17,21 ---- if ($mx_request_vars->is_request('login') && (!$userdata['session_logged_in'] || $mx_request_vars->is_post('admin')) ) { ! $username = $mx_request_vars->is_post('username') ? phpBB2::phpbb_clean_username($mx_request_vars->post('username', MX_TYPE_NO_TAGS)) : ''; $password = $mx_request_vars->post('password', MX_TYPE_NO_TAGS); Index: core.php =================================================================== RCS file: /cvsroot/mxbb/core/includes/sessions/internal/core.php,v retrieving revision 1.13 retrieving revision 1.14 diff -C2 -d -r1.13 -r1.14 *** core.php 4 Oct 2008 07:04:25 -0000 1.13 --- core.php 31 Oct 2008 18:54:23 -0000 1.14 *************** *** 268,272 **** { global $db, $mx_root_path, $phpbb_root_path, $userdata, $mx_user, $lang, $images, $phpEx; ! global $phpBB2, $board_config, $gen_simple_header, $layouttemplate, $mx_page; switch ($mode) --- 268,272 ---- { global $db, $mx_root_path, $phpbb_root_path, $userdata, $mx_user, $lang, $images, $phpEx; ! global $board_config, $gen_simple_header, $layouttemplate, $mx_page; switch ($mode) *************** *** 287,291 **** } ! $s_last_visit = ( $userdata['session_logged_in'] ) ? $phpBB2->create_date($board_config['default_dateformat'], $userdata['user_lastvisit'], $board_config['board_timezone']) : ''; // --- 287,291 ---- } ! $s_last_visit = ( $userdata['session_logged_in'] ) ? phpBB2::create_date($board_config['default_dateformat'], $userdata['user_lastvisit'], $board_config['board_timezone']) : ''; // *************** *** 490,494 **** return $sql; } ! /** * Get username details for placing into templates. --- 490,555 ---- return $sql; } ! ! /** ! * Enter description here... ! * ! * @return unknown ! */ ! function generate_session_online_sql($guest = false) ! { ! if ($guest) ! { ! $sql = "SELECT * ! FROM " . SESSIONS_TABLE . " ! WHERE session_logged_in = 0 ! AND session_time >= " . ( time() - 300 ) . " ! ORDER BY session_time DESC"; ! } ! else ! { ! $sql = "SELECT u.*, s.* ! FROM " . USERS_TABLE . " u, " . SESSIONS_TABLE . " s ! WHERE s.session_logged_in = " . TRUE . " ! AND u.user_id = s.session_user_id ! AND u.user_id <> " . ANONYMOUS . " ! AND s.session_time >= " . ( time() - 300 ) . " ! ORDER BY u.user_session_time DESC"; ! } ! return $sql; ! } ! ! /** ! * Enter description here... ! * ! * @param unknown_type $str_ip ! * @return unknown ! */ ! function decode_ip($str_ip) ! { ! return phpBB2::decode_ip($str_ip); ! } ! ! /** ! * Enter description here... ! * ! * @return unknown ! */ ! function get_phpbb_version() ! { ! return ''; ! } ! ! /** ! * Enter description here... ! * ! * @return unknown ! */ ! function confirm_backend() ! { ! global $portal_config; ! ! return PORTAL_BACKEND == $portal_config['portal_backend']; ! } ! /** * Get username details for placing into templates. *************** *** 502,533 **** * * @return string A string consisting of what is wanted based on $mode. ! */ function get_username_string($mode, $user_id, $username = false, $user_color = false, $guest_username = false, $custom_profile_url = false) { global $lang, $userdata; ! $lang['Guest'] = !$guest_username ? $lang['Guest'] : $guest_username; ! $this_userdata = mx_get_userdata($user_id, false); ! $username = ($username) ? $username : $this_userdata['username']; ! if ($this_userdata['user_level'] == ADMIN) ! { $user_color = $theme['fontcolor3']; ! $user_style = 'style="color:#' . $user_color . '; font-weight : bold;"'; ! } ! else if ($this_userdata['user_level'] == MOD) ! { $user_color = $theme['fontcolor2']; ! $user_style = 'style="color:#' . $user_color . '; font-weight : bold;"'; } ! else ! { $user_colour = $theme['fontcolor1']; ! $topic_poster_style = 'style="font-weight : bold;"'; } ! $profile_url = ''; ! $full_url = (($user_id == ANONYMOUS) || ($user_id == MUSIC_GUEST)) ? '<span ' . $topic_poster_style . '>' . $lang['Guest'] . '</span>' : '<span ' . $topic_poster_style . '>' . $username . '</span>'; --- 563,594 ---- * * @return string A string consisting of what is wanted based on $mode. ! */ function get_username_string($mode, $user_id, $username = false, $user_color = false, $guest_username = false, $custom_profile_url = false) { global $lang, $userdata; ! $lang['Guest'] = !$guest_username ? $lang['Guest'] : $guest_username; ! $this_userdata = mx_get_userdata($user_id, false); ! $username = ($username) ? $username : $this_userdata['username']; ! if ($this_userdata['user_level'] == ADMIN) ! { $user_color = $theme['fontcolor3']; ! $user_style = 'style="color:#' . $user_color . '; font-weight : bold;"'; ! } ! else if ($this_userdata['user_level'] == MOD) ! { $user_color = $theme['fontcolor2']; ! $user_style = 'style="color:#' . $user_color . '; font-weight : bold;"'; } ! else ! { $user_colour = $theme['fontcolor1']; ! $topic_poster_style = 'style="font-weight : bold;"'; } ! $profile_url = ''; ! $full_url = (($user_id == ANONYMOUS) || ($user_id == MUSIC_GUEST)) ? '<span ' . $topic_poster_style . '>' . $lang['Guest'] . '</span>' : '<span ' . $topic_poster_style . '>' . $username . '</span>'; *************** *** 550,556 **** return $full_url; break; ! } ! } ! } --- 611,648 ---- return $full_url; break; ! } ! } ! ! // ! // ACP ! // ! /** ! * Enter description here... ! * ! */ ! function load_phpbb_acp_menu() ! { ! ! } ! ! /** ! * Enter description here... ! * ! */ ! function load_forum_stats() ! { ! ! } ! ! /** ! * Enter description here... ! * ! * @return unknown ! */ ! function phpbb_version_check() ! { ! return ''; ! } ! } Index: bbcode.php =================================================================== RCS file: /cvsroot/mxbb/core/includes/sessions/internal/bbcode.php,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** bbcode.php 4 Oct 2008 07:04:25 -0000 1.1 --- bbcode.php 31 Oct 2008 18:54:23 -0000 1.2 *************** *** 16,34 **** // ! // Here comes a mxp version of original phpbb2 bbcode.php ! // Last in file are the mxp wrapper functions // ! ! define("BBCODE_UID_LEN", 10); ! ! // global that holds loaded-and-prepared bbcode templates, so we only have to do ! // that stuff once. [...1079 lines suppressed...] - 'SMILEY_WIDTH' => $row['smiley_width'], - 'SMILEY_HEIGHT' => $row['smiley_height'], - 'SMILEY_DESC' => $row['emotion']) - ); - } - } - - //What we do here with forum_id versus page_id ? - if ($mode == 'inline' && $display_link) - { - $template->assign_vars(array( - 'S_SHOW_SMILEY_LINK' => true, - 'U_MORE_SMILIES' => mx3_append_sid(PHPBB_URL . "posting.$phpEx", 'mode=smilies&f=' . $forum_id)) - ); - } - */ - if ($mode == 'window') { --- 293,296 ---- |