You can subscribe to this list here.
| 2005 |
Jan
|
Feb
|
Mar
(95) |
Apr
(270) |
May
(111) |
Jun
|
Jul
|
Aug
(64) |
Sep
(130) |
Oct
(319) |
Nov
(17) |
Dec
(191) |
|---|---|---|---|---|---|---|---|---|---|---|---|---|
| 2006 |
Jan
(53) |
Feb
|
Mar
|
Apr
|
May
(6) |
Jun
(387) |
Jul
(102) |
Aug
(247) |
Sep
(120) |
Oct
(1) |
Nov
(8) |
Dec
(21) |
| 2007 |
Jan
(38) |
Feb
(36) |
Mar
|
Apr
(32) |
May
(135) |
Jun
(523) |
Jul
(192) |
Aug
(103) |
Sep
(533) |
Oct
(77) |
Nov
(23) |
Dec
(203) |
| 2008 |
Jan
(312) |
Feb
(1193) |
Mar
(404) |
Apr
(67) |
May
(62) |
Jun
(497) |
Jul
(297) |
Aug
(110) |
Sep
(335) |
Oct
(256) |
Nov
(50) |
Dec
(118) |
| 2009 |
Jan
(67) |
Feb
(10) |
Mar
(1) |
Apr
(1) |
May
|
Jun
(10) |
Jul
(61) |
Aug
|
Sep
(16) |
Oct
(45) |
Nov
(12) |
Dec
(14) |
| 2010 |
Jan
(30) |
Feb
|
Mar
|
Apr
(4) |
May
|
Jun
|
Jul
(7) |
Aug
(7) |
Sep
(5) |
Oct
(5) |
Nov
|
Dec
|
| 2011 |
Jan
(7) |
Feb
(3) |
Mar
(89) |
Apr
(11) |
May
(5) |
Jun
|
Jul
(8) |
Aug
(1) |
Sep
(2) |
Oct
|
Nov
(2) |
Dec
(89) |
| 2012 |
Jan
(7) |
Feb
(1) |
Mar
(1) |
Apr
|
May
|
Jun
|
Jul
|
Aug
(4) |
Sep
(3) |
Oct
(42) |
Nov
(1) |
Dec
|
| 2013 |
Jan
|
Feb
|
Mar
(19) |
Apr
(90) |
May
(38) |
Jun
(235) |
Jul
(38) |
Aug
(10) |
Sep
|
Oct
(29) |
Nov
|
Dec
|
| 2014 |
Jan
|
Feb
|
Mar
|
Apr
(6) |
May
(52) |
Jun
|
Jul
(7) |
Aug
|
Sep
(17) |
Oct
|
Nov
|
Dec
|
|
From: Markus P. <mar...@us...> - 2005-04-19 20:49:50
|
Update of /cvsroot/mxbb/core/modules/mx_coreblocks/templates/subSilver In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv26892 Modified Files: mx_forum.tpl Log Message: Fixed some named array with non-quoted indexes and code layout. Added use of new mx_request_vars class. Index: mx_forum.tpl =================================================================== RCS file: /cvsroot/mxbb/core/modules/mx_coreblocks/templates/subSilver/mx_forum.tpl,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** mx_forum.tpl 9 Jan 2005 21:55:45 -0000 1.3 --- mx_forum.tpl 19 Apr 2005 20:49:28 -0000 1.4 *************** *** 1,5 **** ! <table width="{BLOCK_SIZE}" cellpadding="4" cellspacing="0" border="0" class="forumline"> ! <tr> ! <th colspan="2" class="thCornerL" nowrap="nowrap"> {L_FORUM} </th> <th width="50" class="thTop" nowrap="nowrap"> {L_TOPICS} </th> <th width="50" class="thTop" nowrap="nowrap"> {L_POSTS} </th> --- 1,5 ---- ! <table width="{BLOCK_SIZE}" cellpadding="2" cellspacing="1" border="0" class="forumline"> ! <tr> ! <th colspan="2" class="thCornerL" height="25" nowrap="nowrap"> {L_FORUM} </th> <th width="50" class="thTop" nowrap="nowrap"> {L_TOPICS} </th> <th width="50" class="thTop" nowrap="nowrap"> {L_POSTS} </th> *************** *** 7,16 **** </tr> <!-- BEGIN catrow --> ! <tr> <td class="catLeft" colspan="2" height="28"><span class="cattitle"><a href="{catrow.U_VIEWCAT}" class="cattitle">{catrow.CAT_DESC}</a></span></td> <td class="rowpic" colspan="3" align="right"> </td> </tr> <!-- BEGIN forumrow --> ! <tr> <td class="row1" align="center" valign="middle" height="50"><img src="{U_PHPBB_ROOT_PATH}{catrow.forumrow.FORUM_FOLDER_IMG}" width="46" height="25" alt="{catrow.forumrow.L_FORUM_FOLDER_ALT}" title="{catrow.forumrow.L_FORUM_FOLDER_ALT}" /></td> <td class="row1" width="100%" height="50"><span class="forumlink"> <a href="{catrow.forumrow.U_VIEWFORUM}" class="forumlink">{catrow.forumrow.FORUM_NAME}</a><br /> --- 7,16 ---- </tr> <!-- BEGIN catrow --> ! <tr> <td class="catLeft" colspan="2" height="28"><span class="cattitle"><a href="{catrow.U_VIEWCAT}" class="cattitle">{catrow.CAT_DESC}</a></span></td> <td class="rowpic" colspan="3" align="right"> </td> </tr> <!-- BEGIN forumrow --> ! <tr> <td class="row1" align="center" valign="middle" height="50"><img src="{U_PHPBB_ROOT_PATH}{catrow.forumrow.FORUM_FOLDER_IMG}" width="46" height="25" alt="{catrow.forumrow.L_FORUM_FOLDER_ALT}" title="{catrow.forumrow.L_FORUM_FOLDER_ALT}" /></td> <td class="row1" width="100%" height="50"><span class="forumlink"> <a href="{catrow.forumrow.U_VIEWFORUM}" class="forumlink">{catrow.forumrow.FORUM_NAME}</a><br /> |
|
From: Markus P. <mar...@us...> - 2005-04-19 20:43:32
|
Update of /cvsroot/mxbb/core/modules/mx_coreblocks In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv24437 Modified Files: mx_forum.php Log Message: Fixed some named array with non-quoted indexes and code layout. Added use of new mx_request_vars class. Index: mx_forum.php =================================================================== RCS file: /cvsroot/mxbb/core/modules/mx_coreblocks/mx_forum.php,v retrieving revision 1.5 retrieving revision 1.6 diff -C2 -d -r1.5 -r1.6 *** mx_forum.php 9 Jan 2005 21:55:44 -0000 1.5 --- mx_forum.php 19 Apr 2005 20:43:21 -0000 1.6 *************** *** 21,49 **** * (at your option) any later version. */ ! ! if ( !defined( 'IN_PORTAL' ) ) { ! define( 'IN_PORTAL', 1 ); ! $mx_root_path = "./"; $include_page_tail = 1; ! include( $mx_root_path . 'extension.inc' ); ! include( $mx_root_path . 'common.' . $phpEx ); ! ! // Start session management ! ! $userdata = session_pagestart( $user_ip, PAGE_FORUM ); ! mx_init_userprefs( $userdata ); ! ! // End session management ! } ! $viewcat = ( !empty( $HTTP_GET_VARS[POST_CAT_URL] ) ) ? $HTTP_GET_VARS[POST_CAT_URL] : -1; ! if ( isset( $HTTP_GET_VARS['mark'] ) || isset( $HTTP_POST_VARS['mark'] ) ) { ! $mark_read = ( isset( $HTTP_POST_VARS['mark'] ) ) ? $HTTP_POST_VARS['mark'] : $HTTP_GET_VARS['mark']; } else --- 21,56 ---- * (at your option) any later version. */ ! ! if ( !defined('IN_PORTAL') ) { ! define('IN_PORTAL', 1); ! $mx_root_path = './'; $include_page_tail = 1; ! include($mx_root_path . 'extension.inc'); ! include($mx_root_path . 'common.' . $phpEx); ! ! $userdata = session_pagestart($user_ip, PAGE_FORUM); ! mx_init_userprefs($userdata); } ! // ================================================================================ ! // The following code is based on includes/page_header.php (phpBB 2.0.14) ! // ================================================================================ ! $l_timezone = explode('.', $board_config['board_timezone']); ! $l_timezone = (count($l_timezone) > 1 && $l_timezone[count($l_timezone)-1] != 0) ? $lang[sprintf('%.1f', $board_config['board_timezone'])] : $lang[number_format($board_config['board_timezone'])]; ! ! ! // ================================================================================ ! // The following code is based on index.php (phpBB 2.0.14) ! // ================================================================================ ! ! $viewcat = ( !empty($HTTP_GET_VARS[POST_CAT_URL]) ) ? $HTTP_GET_VARS[POST_CAT_URL] : -1; ! ! if( isset($HTTP_GET_VARS['mark']) || isset($HTTP_POST_VARS['mark']) ) { ! $mark_read = ( isset($HTTP_POST_VARS['mark']) ) ? $HTTP_POST_VARS['mark'] : $HTTP_GET_VARS['mark']; } else *************** *** 52,91 **** } // Handle marking posts ! ! if ( $mark_read == 'forums' ) { ! if ( $userdata['session_logged_in'] ) { ! setcookie( $board_config['cookie_name'] . '_f_all', time(), 0, $board_config['cookie_path'], $board_config['cookie_domain'], $board_config['cookie_secure'] ); } ! $template->assign_vars( array( "META" => '<meta http-equiv="refresh" content="3;url=' . append_sid( PORTAL_URL . "index.$phpEx" ) . '">' ) ! ); ! $message = $lang['Forums_marked_read'] . '<br /><br />' . sprintf( $lang['Click_return_index'], '<a href="' . append_sid( PORTAL_URL . "index.$phpEx" ) . '">', '</a> ' ); ! mx_message_die( GENERAL_MESSAGE, $message ); } ! // End handle marking posts ! $tracking_topics = ( isset( $HTTP_COOKIE_VARS[$board_config['cookie_name'] . '_t'] ) ) ? unserialize( $HTTP_COOKIE_VARS[$board_config['cookie_name'] . "_t"] ) : array(); ! $tracking_forums = ( isset( $HTTP_COOKIE_VARS[$board_config['cookie_name'] . '_f'] ) ) ? unserialize( $HTTP_COOKIE_VARS[$board_config['cookie_name'] . "_f"] ) : array(); // If you don't use these stats on your index you may want to consider // removing them ! ! $total_posts = get_db_stat( 'postcount' ); ! $total_users = get_db_stat( 'usercount' ); ! $newest_userdata = get_db_stat( 'newestuser' ); $newest_user = $newest_userdata['username']; $newest_uid = $newest_userdata['user_id']; ! if ( $total_posts == 0 ) { $l_total_post_s = $lang['Posted_articles_zero_total']; } ! else if ( $total_posts == 1 ) { $l_total_post_s = $lang['Posted_article_total']; --- 59,102 ---- } + // // Handle marking posts ! // ! if( $mark_read == 'forums' ) { ! if( $userdata['session_logged_in'] ) { ! setcookie($board_config['cookie_name'] . '_f_all', time(), 0, $board_config['cookie_path'], $board_config['cookie_domain'], $board_config['cookie_secure']); } ! $template->assign_vars(array( ! "META" => '<meta http-equiv="refresh" content="3;url=' . append_sid(PORTAL_URL . "index.$phpEx") . '">' ) ! ); ! $message = $lang['Forums_marked_read'] . '<br /><br />' . sprintf($lang['Click_return_index'], '<a href="' . append_sid(PORTAL_URL . "index.$phpEx") . '">', '</a> '); ! mx_message_die(GENERAL_MESSAGE, $message); } ! // // End handle marking posts + // ! $tracking_topics = ( isset($HTTP_COOKIE_VARS[$board_config['cookie_name'] . '_t']) ) ? unserialize($HTTP_COOKIE_VARS[$board_config['cookie_name'] . "_t"]) : array(); ! $tracking_forums = ( isset($HTTP_COOKIE_VARS[$board_config['cookie_name'] . '_f']) ) ? unserialize($HTTP_COOKIE_VARS[$board_config['cookie_name'] . "_f"]) : array(); + // // If you don't use these stats on your index you may want to consider // removing them ! // ! $total_posts = get_db_stat('postcount'); ! $total_users = get_db_stat('usercount'); ! $newest_userdata = get_db_stat('newestuser'); $newest_user = $newest_userdata['username']; $newest_uid = $newest_userdata['user_id']; ! if( $total_posts == 0 ) { $l_total_post_s = $lang['Posted_articles_zero_total']; } ! else if( $total_posts == 1 ) { $l_total_post_s = $lang['Posted_article_total']; *************** *** 96,104 **** } ! if ( $total_users == 0 ) { $l_total_user_s = $lang['Registered_users_zero_total']; } ! else if ( $total_users == 1 ) { $l_total_user_s = $lang['Registered_user_total']; --- 107,115 ---- } ! if( $total_users == 0 ) { $l_total_user_s = $lang['Registered_users_zero_total']; } ! else if( $total_users == 1 ) { $l_total_user_s = $lang['Registered_user_total']; *************** *** 109,295 **** } - // Start page proper $sql = "SELECT c.cat_id, c.cat_title, c.cat_order ! FROM " . CATEGORIES_TABLE . " c ! ORDER BY c.cat_order"; ! if ( !( $result = $db->sql_query( $sql ) ) ) { ! mx_message_die( GENERAL_ERROR, 'Could not query categories list', '', __LINE__, __FILE__, $sql ); } ! while ( $category_rows[] = $db->sql_fetchrow( $result ) ); ! if ( ( $total_categories = count( $category_rows ) ) ) { ! // Define appropriate SQL ! ! switch ( SQL_LAYER ) { case 'postgresql': ! $sql = "SELECT f.*, p.post_time, p.post_username, u.username, u.user_id ! FROM " . FORUMS_TABLE . " f, " . POSTS_TABLE . " p, " . USERS_TABLE . " u ! WHERE p.post_id = f.forum_last_post_id ! AND u.user_id = p.poster_id ! UNION ( ! SELECT f.*, NULL, NULL, NULL, NULL ! FROM " . FORUMS_TABLE . " f ! WHERE NOT EXISTS ( ! SELECT p.post_time ! FROM " . POSTS_TABLE . " p ! WHERE p.post_id = f.forum_last_post_id ! ) ! ) ! ORDER BY cat_id, forum_order"; break; case 'oracle': ! $sql = "SELECT f.*, p.post_time, p.post_username, u.username, u.user_id ! FROM " . FORUMS_TABLE . " f, " . POSTS_TABLE . " p, " . USERS_TABLE . " u ! WHERE p.post_id = f.forum_last_post_id(+) ! AND u.user_id = p.poster_id(+) ! ORDER BY f.cat_id, f.forum_order"; break; default: $sql = "SELECT f.*, p.post_time, p.post_username, u.username, u.user_id ! FROM (( " . FORUMS_TABLE . " f ! LEFT JOIN " . POSTS_TABLE . " p ON p.post_id = f.forum_last_post_id ) ! LEFT JOIN " . USERS_TABLE . " u ON u.user_id = p.poster_id ) ! ORDER BY f.cat_id, f.forum_order"; break; } ! if ( !( $result = $db->sql_query( $sql ) ) ) { ! mx_message_die( GENERAL_ERROR, 'Could not query forums information', '', __LINE__, __FILE__, $sql ); } $forum_data = array(); ! while ( $row = $db->sql_fetchrow( $result ) ) { $forum_data[] = $row; } ! if ( !( $total_forums = count( $forum_data ) ) ) { ! mx_message_die( GENERAL_MESSAGE, $lang['No_forums'] ); } ! // Obtain a list of topic ids which contain // posts made since user last visited ! if ( $userdata['session_logged_in'] ) { ! $sql = "SELECT t.forum_id, t.topic_id, p.post_time ! FROM " . TOPICS_TABLE . " t, " . POSTS_TABLE . " p ! WHERE p.post_id = t.topic_last_post_id ! AND p.post_time > " . $userdata['user_lastvisit'] . " ! AND t.topic_moved_id = 0"; ! if ( !( $result = $db->sql_query( $sql ) ) ) { ! mx_message_die( GENERAL_ERROR, 'Could not query new topic information', '', __LINE__, __FILE__, $sql ); } $new_topic_data = array(); ! while ( $topic_data = $db->sql_fetchrow( $result ) ) { $new_topic_data[$topic_data['forum_id']][$topic_data['topic_id']] = $topic_data['post_time']; } } ! // Obtain list of moderators of each forum // First users, then groups ... broken into two queries ! ! $sql = "SELECT aa.forum_id, u.user_id, u.username ! FROM " . AUTH_ACCESS_TABLE . " aa, " . USER_GROUP_TABLE . " ug, " . GROUPS_TABLE . " g, " . USERS_TABLE . " u ! WHERE aa.auth_mod = " . true . " ! AND g.group_single_user = 1 ! AND ug.group_id = aa.group_id ! AND g.group_id = aa.group_id ! AND u.user_id = ug.user_id ! GROUP BY u.user_id, u.username, aa.forum_id ! ORDER BY aa.forum_id, u.user_id"; ! if ( !( $result = $db->sql_query( $sql ) ) ) { ! mx_message_die( GENERAL_ERROR, 'Could not query forum moderator information', '', __LINE__, __FILE__, $sql ); } $forum_moderators = array(); ! while ( $row = $db->sql_fetchrow( $result ) ) { ! $forum_moderators[$row['forum_id']][] = '<a href="' . append_sid( PHPBB_URL . "profile.$phpEx?mode=viewprofile&" . POST_USERS_URL . "=" . $row['user_id'] ) . '">' . $row['username'] . '</a>'; } ! $sql = "SELECT aa.forum_id, g.group_id, g.group_name ! FROM " . AUTH_ACCESS_TABLE . " aa, " . USER_GROUP_TABLE . " ug, " . GROUPS_TABLE . " g ! WHERE aa.auth_mod = " . true . " ! AND g.group_single_user = 0 ! AND g.group_type <> " . GROUP_HIDDEN . " ! AND ug.group_id = aa.group_id ! AND g.group_id = aa.group_id ! GROUP BY g.group_id, g.group_name, aa.forum_id ! ORDER BY aa.forum_id, g.group_id"; ! if ( !( $result = $db->sql_query( $sql ) ) ) { ! mx_message_die( GENERAL_ERROR, 'Could not query forum moderator information', '', __LINE__, __FILE__, $sql ); } ! while ( $row = $db->sql_fetchrow( $result ) ) { ! $forum_moderators[$row['forum_id']][] = '<a href="' . append_sid( PHPBB_URL . "groupcp.$phpEx?" . POST_GROUPS_URL . "=" . $row['group_id'] ) . '">' . $row['group_name'] . '</a>'; } ! // Find which forums are visible for this user ! $is_auth_ary = array(); ! $is_auth_ary = auth( AUTH_VIEW, AUTH_LIST_ALL, $userdata, $forum_data ); ! // Start output of page ! ! $template->set_filenames( array( 'block_forum' => 'mx_forum.tpl' ) ! ); ! $template->assign_vars( array( 'BLOCK_SIZE' => $block_size, ! 'TOTAL_POSTS' => sprintf( $l_total_post_s, $total_posts ), ! 'TOTAL_USERS' => sprintf( $l_total_user_s, $total_users ), ! 'NEWEST_USER' => sprintf( $lang['Newest_user'], '<a href="' . append_sid( PHPBB_URL . "profile.$phpEx?mode=viewprofile&" . POST_USERS_URL . "=$newest_uid" ) . '">', $newest_user, '</a>' ), ! 'FORUM_IMG' => $images['forum'], ! 'FORUM_NEW_IMG' => $images['forum_new'], ! 'FORUM_LOCKED_IMG' => $images['forum_locked'], ! 'U_PHPBB_ROOT_PATH' => PHPBB_URL, ! 'TEMPLATE_ROOT_PATH' => TEMPLATE_ROOT_PATH, ! 'L_FORUM' => $lang['Forum'], ! 'L_TOPICS' => $lang['Topics'], ! 'L_REPLIES' => $lang['Replies'], ! 'L_VIEWS' => $lang['Views'], ! 'L_POSTS' => $lang['Posts'], ! 'L_LASTPOST' => $lang['Last_Post'], ! 'L_NO_NEW_POSTS' => $lang['No_new_posts'], ! 'L_NEW_POSTS' => $lang['New_posts'], ! 'L_NO_NEW_POSTS_LOCKED' => $lang['No_new_posts_locked'], ! 'L_NEW_POSTS_LOCKED' => $lang['New_posts_locked'], ! 'L_ONLINE_EXPLAIN' => $lang['Online_explain'], ! 'L_MODERATOR' => $lang['Moderators'], ! 'L_FORUM_LOCKED' => $lang['Forum_is_locked'], ! 'L_MARK_FORUMS_READ' => $lang['Mark_all_forums'], ! 'U_MARK_READ' => append_sid( PORTAL_URL . "mx_forum.$phpEx?mark=forums" ) ! ) ); ! // Okay, let's build the index ! ! for( $i = 0; $i < $total_categories; $i++ ) { $cat_id = $category_rows[$i]['cat_id']; ! // Should we display this category/forum set? ! $display_forums = false; ! for( $j = 0; $j < $total_forums; $j++ ) { if ( $is_auth_ary[$forum_data[$j]['forum_id']]['auth_view'] && $forum_data[$j]['cat_id'] == $cat_id ) --- 120,323 ---- } + // + // Start page proper + // $sql = "SELECT c.cat_id, c.cat_title, c.cat_order ! FROM " . CATEGORIES_TABLE . " c ! ORDER BY c.cat_order"; ! if( !($result = $db->sql_query($sql)) ) { ! mx_message_die(GENERAL_ERROR, 'Could not query categories list', '', __LINE__, __FILE__, $sql); } ! $category_rows = array(); ! while( $category_rows[] = $db->sql_fetchrow($result) ); ! $db->sql_freeresult($result); ! if( ( $total_categories = count($category_rows) ) ) { ! // // Define appropriate SQL ! // ! switch(SQL_LAYER) { case 'postgresql': ! $sql = "SELECT f.*, p.post_time, p.post_username, u.username, u.user_id ! FROM " . FORUMS_TABLE . " f, " . POSTS_TABLE . " p, " . USERS_TABLE . " u ! WHERE p.post_id = f.forum_last_post_id ! AND u.user_id = p.poster_id ! UNION ( ! SELECT f.*, NULL, NULL, NULL, NULL ! FROM " . FORUMS_TABLE . " f ! WHERE NOT EXISTS ( ! SELECT p.post_time ! FROM " . POSTS_TABLE . " p ! WHERE p.post_id = f.forum_last_post_id ! ) ! ) ! ORDER BY cat_id, forum_order"; break; case 'oracle': ! $sql = "SELECT f.*, p.post_time, p.post_username, u.username, u.user_id ! FROM " . FORUMS_TABLE . " f, " . POSTS_TABLE . " p, " . USERS_TABLE . " u ! WHERE p.post_id = f.forum_last_post_id(+) ! AND u.user_id = p.poster_id(+) ! ORDER BY f.cat_id, f.forum_order"; break; default: $sql = "SELECT f.*, p.post_time, p.post_username, u.username, u.user_id ! FROM (( " . FORUMS_TABLE . " f ! LEFT JOIN " . POSTS_TABLE . " p ON p.post_id = f.forum_last_post_id ) ! LEFT JOIN " . USERS_TABLE . " u ON u.user_id = p.poster_id ) ! ORDER BY f.cat_id, f.forum_order"; break; } ! if ( !($result = $db->sql_query($sql)) ) { ! mx_message_die(GENERAL_ERROR, 'Could not query forums information', '', __LINE__, __FILE__, $sql); } $forum_data = array(); ! while( $row = $db->sql_fetchrow($result) ) { $forum_data[] = $row; } + $db->sql_freeresult($result); ! if ( !($total_forums = count($forum_data)) ) { ! mx_message_die(GENERAL_MESSAGE, $lang['No_forums']); } ! ! // // Obtain a list of topic ids which contain // posts made since user last visited ! // if ( $userdata['session_logged_in'] ) { ! $sql = "SELECT t.forum_id, t.topic_id, p.post_time ! FROM " . TOPICS_TABLE . " t, " . POSTS_TABLE . " p ! WHERE p.post_id = t.topic_last_post_id ! AND p.post_time > " . $userdata['user_lastvisit'] . " ! AND t.topic_moved_id = 0"; ! if ( !($result = $db->sql_query($sql)) ) { ! mx_message_die(GENERAL_ERROR, 'Could not query new topic information', '', __LINE__, __FILE__, $sql); } $new_topic_data = array(); ! while( $topic_data = $db->sql_fetchrow($result) ) { $new_topic_data[$topic_data['forum_id']][$topic_data['topic_id']] = $topic_data['post_time']; } + $db->sql_freeresult($result); } ! ! // // Obtain list of moderators of each forum // First users, then groups ... broken into two queries ! // ! $sql = "SELECT aa.forum_id, u.user_id, u.username ! FROM " . AUTH_ACCESS_TABLE . " aa, " . USER_GROUP_TABLE . " ug, " . GROUPS_TABLE . " g, " . USERS_TABLE . " u ! WHERE aa.auth_mod = " . TRUE . " ! AND g.group_single_user = 1 ! AND ug.group_id = aa.group_id ! AND g.group_id = aa.group_id ! AND u.user_id = ug.user_id ! GROUP BY u.user_id, u.username, aa.forum_id ! ORDER BY aa.forum_id, u.user_id"; ! if ( !($result = $db->sql_query($sql)) ) { ! mx_message_die(GENERAL_ERROR, 'Could not query forum moderator information', '', __LINE__, __FILE__, $sql); } $forum_moderators = array(); ! while( $row = $db->sql_fetchrow($result) ) { ! $forum_moderators[$row['forum_id']][] = '<a href="' . append_sid(PHPBB_URL . "profile.$phpEx?mode=viewprofile&" . POST_USERS_URL . "=" . $row['user_id']) . '">' . $row['username'] . '</a>'; } + $db->sql_freeresult($result); ! $sql = "SELECT aa.forum_id, g.group_id, g.group_name ! FROM " . AUTH_ACCESS_TABLE . " aa, " . USER_GROUP_TABLE . " ug, " . GROUPS_TABLE . " g ! WHERE aa.auth_mod = " . TRUE . " ! AND g.group_single_user = 0 ! AND g.group_type <> " . GROUP_HIDDEN . " ! AND ug.group_id = aa.group_id ! AND g.group_id = aa.group_id ! GROUP BY g.group_id, g.group_name, aa.forum_id ! ORDER BY aa.forum_id, g.group_id"; ! if ( !($result = $db->sql_query($sql)) ) { ! mx_message_die(GENERAL_ERROR, 'Could not query forum moderator information', '', __LINE__, __FILE__, $sql); } ! while( $row = $db->sql_fetchrow($result) ) { ! $forum_moderators[$row['forum_id']][] = '<a href="' . append_sid(PHPBB_URL . "groupcp.$phpEx?" . POST_GROUPS_URL . "=" . $row['group_id']) . '">' . $row['group_name'] . '</a>'; } ! $db->sql_freeresult($result); ! ! // // Find which forums are visible for this user ! // $is_auth_ary = array(); ! $is_auth_ary = auth(AUTH_VIEW, AUTH_LIST_ALL, $userdata, $forum_data); ! ! // // Start output of page ! // ! $template->set_filenames(array( ! 'block_forum' => 'mx_forum.tpl') ! ); ! $template->assign_vars(array( ! 'BLOCK_SIZE' => $block_size, ! 'U_PHPBB_ROOT_PATH' => PHPBB_URL, ! 'TEMPLATE_ROOT_PATH' => TEMPLATE_ROOT_PATH, ! 'S_TIMEZONE' => sprintf($lang['All_times'], $l_timezone), ! 'TOTAL_POSTS' => sprintf($l_total_post_s, $total_posts), ! 'TOTAL_USERS' => sprintf($l_total_user_s, $total_users), ! 'NEWEST_USER' => sprintf($lang['Newest_user'], '<a href="' . append_sid(PHPBB_URL . "profile.$phpEx?mode=viewprofile&" . POST_USERS_URL . "=$newest_uid") . '">', $newest_user, '</a>'), ! 'FORUM_IMG' => $images['forum'], ! 'FORUM_NEW_IMG' => $images['forum_new'], ! 'FORUM_LOCKED_IMG' => $images['forum_locked'], ! 'L_FORUM' => $lang['Forum'], ! 'L_TOPICS' => $lang['Topics'], ! 'L_REPLIES' => $lang['Replies'], ! 'L_VIEWS' => $lang['Views'], ! 'L_POSTS' => $lang['Posts'], ! 'L_LASTPOST' => $lang['Last_Post'], ! 'L_NO_NEW_POSTS' => $lang['No_new_posts'], ! 'L_NEW_POSTS' => $lang['New_posts'], ! 'L_NO_NEW_POSTS_LOCKED' => $lang['No_new_posts_locked'], ! 'L_NEW_POSTS_LOCKED' => $lang['New_posts_locked'], ! 'L_ONLINE_EXPLAIN' => $lang['Online_explain'], ! 'L_MODERATOR' => $lang['Moderators'], ! 'L_FORUM_LOCKED' => $lang['Forum_is_locked'], ! 'L_MARK_FORUMS_READ' => $lang['Mark_all_forums'], ! 'U_MARK_READ' => append_sid(PORTAL_URL . "mx_forum.$phpEx?mark=forums")) ! ); ! ! // // Okay, let's build the index ! // ! for($i = 0; $i < $total_categories; $i++) { $cat_id = $category_rows[$i]['cat_id']; ! ! // // Should we display this category/forum set? ! // $display_forums = false; ! for($j = 0; $j < $total_forums; $j++) { if ( $is_auth_ary[$forum_data[$j]['forum_id']]['auth_view'] && $forum_data[$j]['cat_id'] == $cat_id ) *************** *** 297,315 **** $display_forums = true; } ! } ! // Yes, we should, so first dump out the category // title, then, if appropriate the forum list ! if ( $display_forums ) { ! $template->assign_block_vars( 'catrow', array( 'CAT_ID' => $cat_id, ! 'CAT_DESC' => $category_rows[$i]['cat_title'], ! 'U_VIEWCAT' => append_sid( PHPBB_URL . "index.$phpEx?" . POST_CAT_URL . "=$cat_id" ) ! ) ); if ( $viewcat == $cat_id || $viewcat == -1 ) { ! for( $j = 0; $j < $total_forums; $j++ ) { if ( $forum_data[$j]['cat_id'] == $cat_id ) --- 325,345 ---- $display_forums = true; } ! } ! ! // // Yes, we should, so first dump out the category // title, then, if appropriate the forum list ! // if ( $display_forums ) { ! $template->assign_block_vars('catrow', array( ! 'CAT_ID' => $cat_id, ! 'CAT_DESC' => $category_rows[$i]['cat_title'], ! 'U_VIEWCAT' => append_sid(PHPBB_URL . "index.$phpEx?" . POST_CAT_URL . "=$cat_id")) ! ); if ( $viewcat == $cat_id || $viewcat == -1 ) { ! for($j = 0; $j < $total_forums; $j++) { if ( $forum_data[$j]['cat_id'] == $cat_id ) *************** *** 329,342 **** if ( $userdata['session_logged_in'] ) { ! if ( !empty( $new_topic_data[$forum_id] ) ) { $forum_last_post_time = 0; ! while ( list( $check_topic_id, $check_post_time ) = @each( $new_topic_data[$forum_id] ) ) { ! if ( empty( $tracking_topics[$check_topic_id] ) ) { $unread_topics = true; ! $forum_last_post_time = max( $check_post_time, $forum_last_post_time ); } else --- 359,373 ---- if ( $userdata['session_logged_in'] ) { ! if ( !empty($new_topic_data[$forum_id]) ) { $forum_last_post_time = 0; ! while( list($check_topic_id, $check_post_time) = @each($new_topic_data[$forum_id]) ) { ! if ( empty($tracking_topics[$check_topic_id]) ) { $unread_topics = true; ! $forum_last_post_time = max($check_post_time, $forum_last_post_time); ! } else *************** *** 345,354 **** { $unread_topics = true; ! $forum_last_post_time = max( $check_post_time, $forum_last_post_time ); } } } ! if ( !empty( $tracking_forums[$forum_id] ) ) { if ( $tracking_forums[$forum_id] > $forum_last_post_time ) --- 376,385 ---- { $unread_topics = true; ! $forum_last_post_time = max($check_post_time, $forum_last_post_time); } } } ! if ( !empty($tracking_forums[$forum_id]) ) { if ( $tracking_forums[$forum_id] > $forum_last_post_time ) *************** *** 358,362 **** } ! if ( isset( $HTTP_COOKIE_VARS[$board_config['cookie_name'] . '_f_all'] ) ) { if ( $HTTP_COOKIE_VARS[$board_config['cookie_name'] . '_f_all'] > $forum_last_post_time ) --- 389,393 ---- } ! if ( isset($HTTP_COOKIE_VARS[$board_config['cookie_name'] . '_f_all']) ) { if ( $HTTP_COOKIE_VARS[$board_config['cookie_name'] . '_f_all'] > $forum_last_post_time ) *************** *** 365,368 **** --- 396,400 ---- } } + } } *************** *** 377,387 **** if ( $forum_data[$j]['forum_last_post_id'] ) { ! $last_post_time = create_date( $board_config['default_dateformat'], $forum_data[$j]['post_time'], $board_config['board_timezone'] ); $last_post = $last_post_time . '<br />'; ! $last_post .= ( $forum_data[$j]['user_id'] == ANONYMOUS ) ? ( ( $forum_data[$j]['post_username'] != '' ) ? $forum_data[$j]['post_username'] . ' ' : $lang['Guest'] . ' ' ) : '<a href="' . append_sid( PHPBB_URL . "profile.$phpEx?mode=viewprofile&" . POST_USERS_URL . '=' . $forum_data[$j]['user_id'] ) . '">' . $forum_data[$j]['username'] . '</a> '; ! $last_post .= '<a href="' . append_sid( PHPBB_URL . "viewtopic.$phpEx?" . POST_POST_URL . '=' . $forum_data[$j]['forum_last_post_id'] ) . '#' . $forum_data[$j]['forum_last_post_id'] . '"><img src="' . PHPBB_URL . $images['icon_latest_reply'] . '" border="0" alt="' . $lang['View_latest_post'] . '" title="' . $lang['View_latest_post'] . '" /></a>'; } else --- 409,419 ---- if ( $forum_data[$j]['forum_last_post_id'] ) { ! $last_post_time = create_date($board_config['default_dateformat'], $forum_data[$j]['post_time'], $board_config['board_timezone']); $last_post = $last_post_time . '<br />'; ! $last_post .= ( $forum_data[$j]['user_id'] == ANONYMOUS ) ? ( ($forum_data[$j]['post_username'] != '' ) ? $forum_data[$j]['post_username'] . ' ' : $lang['Guest'] . ' ' ) : '<a href="' . append_sid(PHPBB_URL . "profile.$phpEx?mode=viewprofile&" . POST_USERS_URL . '=' . $forum_data[$j]['user_id']) . '">' . $forum_data[$j]['username'] . '</a> '; ! $last_post .= '<a href="' . append_sid(PHPBB_URL . "viewtopic.$phpEx?" . POST_POST_URL . '=' . $forum_data[$j]['forum_last_post_id']) . '#' . $forum_data[$j]['forum_last_post_id'] . '"><img src="' . PHPBB_URL . $images['icon_latest_reply'] . '" border="0" alt="' . $lang['View_latest_post'] . '" title="' . $lang['View_latest_post'] . '" /></a>'; } else *************** *** 390,397 **** } ! if ( count( $forum_moderators[$forum_id] ) > 0 ) { ! $l_moderators = ( count( $forum_moderators[$forum_id] ) == 1 ) ? $lang['Moderator'] : $lang['Moderators']; ! $moderator_list = implode( ', ', $forum_moderators[$forum_id] ); } else --- 422,429 ---- } ! if ( count($forum_moderators[$forum_id]) > 0 ) { ! $l_moderators = ( count($forum_moderators[$forum_id]) == 1 ) ? $lang['Moderator'] : $lang['Moderators']; ! $moderator_list = implode(', ', $forum_moderators[$forum_id]); } else *************** *** 401,422 **** } ! $row_color = ( !( $i % 2 ) ) ? $theme['td_color1'] : $theme['td_color2']; ! $row_class = ( !( $i % 2 ) ) ? $theme['td_class1'] : $theme['td_class2']; ! $template->assign_block_vars( 'catrow.forumrow', array( 'ROW_COLOR' => '#' . $row_color, ! 'ROW_CLASS' => $row_class, ! 'FORUM_FOLDER_IMG' => $folder_image, ! 'FORUM_NAME' => $forum_data[$j]['forum_name'], ! 'FORUM_DESC' => $forum_data[$j]['forum_desc'], ! 'POSTS' => $forum_data[$j]['forum_posts'], ! 'TOPICS' => $forum_data[$j]['forum_topics'], ! 'LAST_POST' => $last_post, ! 'MODERATORS' => $moderator_list, ! 'L_MODERATOR' => $l_moderators, ! 'L_FORUM_FOLDER_ALT' => $folder_alt, ! 'U_VIEWFORUM' => append_sid( PHPBB_URL . "viewforum.$phpEx?" . POST_FORUM_URL . "=$forum_id" ) ! ) ); } } --- 433,455 ---- } ! $row_color = ( !($i % 2) ) ? $theme['td_color1'] : $theme['td_color2']; ! $row_class = ( !($i % 2) ) ? $theme['td_class1'] : $theme['td_class2']; ! $template->assign_block_vars('catrow.forumrow', array( ! 'ROW_COLOR' => '#' . $row_color, ! 'ROW_CLASS' => $row_class, ! 'FORUM_FOLDER_IMG' => $folder_image, ! 'FORUM_NAME' => $forum_data[$j]['forum_name'], ! 'FORUM_DESC' => $forum_data[$j]['forum_desc'], ! 'POSTS' => $forum_data[$j]['forum_posts'], ! 'TOPICS' => $forum_data[$j]['forum_topics'], ! 'LAST_POST' => $last_post, ! 'MODERATORS' => $moderator_list, ! 'L_MODERATOR' => $l_moderators, ! 'L_FORUM_FOLDER_ALT' => $folder_alt, ! 'U_VIEWFORUM' => append_sid(PHPBB_URL . "viewforum.$phpEx?" . POST_FORUM_URL . "=$forum_id")) ! ); } } *************** *** 425,450 **** } } // for ... categories ! } // if ... total_categories else { ! mx_message_die( GENERAL_MESSAGE, $lang['No_forums'] ); } // Generate the page ! ! if ( !empty( $include_page_tail ) ) { ! $page_title = ( !empty( $lang['Forum'] ) ? $lang['Forum'] : 'Forum' ); ! include( $mx_root_path . 'includes/page_header.' . $phpEx ); } ! $template->pparse( 'block_forum' ); ! ! $template->destroy(); ! if ( !empty( $include_page_tail ) ) { ! include( $mx_root_path . 'includes/page_tail.' . $phpEx ); ! unset( $include_page_tail ); } --- 458,483 ---- } } // for ... categories ! ! }// if ... total_categories else { ! mx_message_die(GENERAL_MESSAGE, $lang['No_forums']); } + // // Generate the page ! // ! if ( isset($include_page_tail) ) { ! $page_title = ( !empty($lang['Forum']) ? $lang['Forum'] : 'Forum' ); ! include($mx_root_path . 'includes/page_header.' . $phpEx); } ! $template->pparse('block_forum'); ! if ( isset($include_page_tail) ) { ! include($mx_root_path . 'includes/page_tail.' . $phpEx); ! unset($include_page_tail); } |
|
From: Markus P. <mar...@us...> - 2005-04-19 19:59:45
|
Update of /cvsroot/mxbb/core/modules/mx_coreblocks In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv31885/modules/mx_coreblocks Modified Files: mx_menu_nav.php Log Message: Fixed some named array with non-quoted indexes and code layout. Added use of new mx_request_vars class. Index: mx_menu_nav.php =================================================================== RCS file: /cvsroot/mxbb/core/modules/mx_coreblocks/mx_menu_nav.php,v retrieving revision 1.19 retrieving revision 1.20 diff -C2 -d -r1.19 -r1.20 *** mx_menu_nav.php 6 Mar 2005 01:10:13 -0000 1.19 --- mx_menu_nav.php 19 Apr 2005 19:59:34 -0000 1.20 *************** *** 19,136 **** * (at your option) any later version. */ ! ! $block_config = read_block_config( $block_id ); $title = $block_config[$block_id]['block_title']; $b_description = $block_config[$block_id]['block_desc']; // Setup config parameters ! $config_name = array( 'menu_display_mode', 'menu_page_sync' ); ! for( $i = 0; $i < count( $config_name ); $i++ ) { $config_value = $block_config[$block_id][$config_name[$i]]['parameter_value']; $mx_menu_config[$config_name[$i]] = $config_value; } // Define some parameters $menu_display_mode = $mx_menu_config['menu_display_mode']; ! $menu_page_sync = $mx_menu_config['menu_page_sync'] != 'No'; $sql1 = "SELECT cat_id FROM " . MENU_CAT_TABLE . " ! ORDER BY cat_order, cat_id "; ! ! if ( !( $result_show = $db->sql_query( $sql1 ) ) ) { ! mx_message_die( GENERAL_ERROR, 'Could not obtain folded/unfolded information', '', __LINE__, __FILE__, $sql ); } ! $menu_cat_show = $db->sql_fetchrowset( $result_show ); ! for( $catrow_count = 0; $catrow_count < count( $menu_cat_show ); $catrow_count++ ) { ! $show .= ',' . $menu_cat_show[$catrow_count][cat_id]; } ! $show = substr ( $show, 1 ); // Get the current MX page. ! $page_id = ( !empty( $HTTP_POST_VARS['page'] ) ) ? intval( $HTTP_POST_VARS['page'] ) : intval( $HTTP_GET_VARS['page'] ); ! if ( empty( $page_id ) ) ! { ! $page_id = 1; ! } ! ! switch ( $menu_display_mode ) { case 'Vertical': ! $template->set_filenames( array( "body" => 'mx_menu_nav.tpl' ) ! ); break; case 'Horizontal': ! $template->set_filenames( array( "body" => 'mx_menu_nav_horizontal.tpl' ) ! ); break; default: ! $template->set_filenames( array( "body" => 'mx_menu_nav.tpl' ) ! ); break; } ! $sql = "SELECT cat_id , ! cat_show , ! cat_title , ! cat_desc , ! cat_url , ! cat_target , ! bbcode_uid ! FROM " . MENU_CAT_TABLE . " WHERE block_id = $block_id ORDER BY cat_order, cat_id "; ! ! if ( !( $result_cat = $db->sql_query( $sql ) ) ) { ! mx_message_die( GENERAL_ERROR, 'Could not obtain menu navigation configuration', '', __LINE__, __FILE__, $sql ); } ! $menu_cat_config = $db->sql_fetchrowset( $result_cat ); ! $num_of_cats = count( $menu_cat_config ); ! $cat_width = $num_of_cats > 0 ? ceil( 100 / $num_of_cats ) . '%' : '100%'; ! $template->assign_vars( array( 'BLOCK_SIZE' => ( !empty( $block_size ) ? $block_size : '100%' ), ! 'L_TITLE' => $title, ! 'L_DESC' => $b_description, ! 'S_ACTION' => $edit_url, ! 'EDIT_IMG' => $edit_img, ! 'NUM_OF_CATS' => $num_of_cats, ! 'NUM_OF_CATS_EDIT' => $num_of_cats - 1, ! 'CAT_WIDTH' => $cat_width, ! 'S_HIDDEN_FORM_FIELDS' => $s_hidden_fields ! ) ); for( $catrow_count = 0; $catrow_count < $num_of_cats; $catrow_count++ ) { ! $cat_title = $menu_cat_config[$catrow_count][cat_title]; ! $cat_id = $menu_cat_config[$catrow_count][cat_id]; ! $cat = ( !empty( $lang[$cat_title] ) ? $lang[$cat_title] : $cat_title ); $bbcode_uid = $menu_cat_config[$catrow_count]['bbcode_uid']; ! $cat = mx_decode( $cat, $bbcode_uid ) ; $cat_desc = ''; $cat_icon = '<img border="0" src="' . PORTAL_URL . TEMPLATE_ROOT_PATH . 'images/minus.gif" /> '; ! $cat_url = append_sid( PORTAL_URL . 'index.' . $phpEx . '?page=' . $page_id . '&show=' . $show . '&out=' . $cat_id ); ! if ( !empty( $show ) ) { ! $show_lst = $show . "," . $cat_id ; } else { ! $show_lst = $cat_id ; } ! $cat_desc = $menu_cat_config[$catrow_count][cat_desc]; ! $cat_desc = mx_decode( $cat_desc, $bbcode_uid ) ; ! $cat_desc = $cat_desc != '' ? $cat_desc . '<hr>' : ''; $cat_icon = '<img align="absmiddle" border="0" src="' . PORTAL_URL . TEMPLATE_ROOT_PATH . 'images/plus.gif" /> '; ! $cat_url = append_sid( PORTAL_URL . 'index.' . $phpEx . '?page=' . $page_id . '&show=' . $show_lst ); $cat_nav_icon_url = PORTAL_URL . TEMPLATE_ROOT_PATH . 'images/'; --- 19,134 ---- * (at your option) any later version. */ ! ! // ! // Read block settings ! // ! $block_config = read_block_config($block_id); $title = $block_config[$block_id]['block_title']; $b_description = $block_config[$block_id]['block_desc']; + + // // Setup config parameters ! // ! $config_name = array('menu_display_mode', 'menu_page_sync'); ! for( $i = 0; $i < count($config_name); $i++ ) { $config_value = $block_config[$block_id][$config_name[$i]]['parameter_value']; $mx_menu_config[$config_name[$i]] = $config_value; } + + // // Define some parameters + // $menu_display_mode = $mx_menu_config['menu_display_mode']; ! $menu_page_sync = ( $mx_menu_config['menu_page_sync'] != 'No' ); $sql1 = "SELECT cat_id FROM " . MENU_CAT_TABLE . " ! ORDER BY cat_order, cat_id"; ! if ( !($result_show = $db->sql_query($sql1)) ) { ! mx_message_die(GENERAL_ERROR, 'Could not obtain folded/unfolded information', '', __LINE__, __FILE__, $sql); } ! $menu_cat_show = $db->sql_fetchrowset($result_show); ! for( $catrow_count = 0; $catrow_count < count($menu_cat_show); $catrow_count++ ) { ! $show .= ',' . $menu_cat_show[$catrow_count]['cat_id']; } ! $show = substr($show, 1); + // // Get the current MX page. + // + $page_id = $mx_request_vars->request('page', MX_TYPE_INT, 1); ! switch( $menu_display_mode ) { case 'Vertical': ! $template->set_filenames(array('body' => 'mx_menu_nav.tpl')); break; case 'Horizontal': ! $template->set_filenames(array('body' => 'mx_menu_nav_horizontal.tpl')); break; default: ! $template->set_filenames(array('body' => 'mx_menu_nav.tpl')); break; } ! $sql = "SELECT * ! FROM " . MENU_CAT_TABLE . " ! WHERE block_id = $block_id ! ORDER BY cat_order, cat_id"; ! if ( !($result_cat = $db->sql_query($sql)) ) { ! mx_message_die(GENERAL_ERROR, 'Could not obtain menu navigation configuration', '', __LINE__, __FILE__, $sql); } ! $menu_cat_config = $db->sql_fetchrowset($result_cat); ! $num_of_cats = count($menu_cat_config); ! $cat_width = $num_of_cats > 0 ? ceil(100 / $num_of_cats) . '%' : '100%'; ! $template->assign_vars(array( ! 'BLOCK_SIZE' => ( !empty($block_size) ? $block_size : '100%' ), ! 'L_TITLE' => $title, ! 'L_DESC' => $b_description, ! 'S_ACTION' => $edit_url, ! 'EDIT_IMG' => $edit_img, ! 'NUM_OF_CATS' => $num_of_cats, ! 'NUM_OF_CATS_EDIT' => $num_of_cats - 1, ! 'CAT_WIDTH' => $cat_width, ! 'S_HIDDEN_FORM_FIELDS' => $s_hidden_fields ! )); for( $catrow_count = 0; $catrow_count < $num_of_cats; $catrow_count++ ) { ! $cat_title = $menu_cat_config[$catrow_count]['cat_title']; ! $cat_id = $menu_cat_config[$catrow_count]['cat_id']; ! $cat = ( !empty($lang[$cat_title]) ? $lang[$cat_title] : $cat_title ); $bbcode_uid = $menu_cat_config[$catrow_count]['bbcode_uid']; ! $cat = mx_decode($cat, $bbcode_uid); $cat_desc = ''; $cat_icon = '<img border="0" src="' . PORTAL_URL . TEMPLATE_ROOT_PATH . 'images/minus.gif" /> '; ! $cat_url = append_sid(PORTAL_URL . 'index.' . $phpEx . '?page=' . $page_id . '&show=' . $show . '&out=' . $cat_id); ! if ( !empty($show) ) { ! $show_lst = $show . "," . $cat_id; } else { ! $show_lst = $cat_id; } ! $cat_desc = $menu_cat_config[$catrow_count]['cat_desc']; ! $cat_desc = mx_decode($cat_desc, $bbcode_uid); ! $cat_desc = ( $cat_desc != '' ? $cat_desc . '<hr />' : '' ); $cat_icon = '<img align="absmiddle" border="0" src="' . PORTAL_URL . TEMPLATE_ROOT_PATH . 'images/plus.gif" /> '; ! $cat_url = append_sid(PORTAL_URL . 'index.' . $phpEx . '?page=' . $page_id . '&show=' . $show_lst); $cat_nav_icon_url = PORTAL_URL . TEMPLATE_ROOT_PATH . 'images/'; *************** *** 138,307 **** $cat_target = ( $menu_cat_config[$catrow_count]['cat_target'] == 0 ) ? '' : '_blank'; ! $cat_url_tmp = append_sid( 'index.php?page=' . $menu_cat_config[$catrow_count]['cat_url'] ) ; $catt = ( $menu_cat_config[$catrow_count]['cat_url'] != 0 ) ? '<a class="genmed" href="' . $cat_url_tmp . '" target="' . $cat_target . '" /><span class="genmed">' . $cat . '</span></a>' : $cat; ! $sql = "SELECT menu_id , ! cat_id , ! menu_name , ! menu_desc , ! menu_links , ! block_id , ! function_id , ! page_id , ! auth_view , ! auth_view_group , ! link_target , ! menu_order , ! bbcode_uid , ! menu_icon ! FROM " . MENU_NAV_TABLE . " WHERE cat_id = " . $cat_id . " ORDER BY menu_order, menu_id "; ! ! if ( !( $result = $db->sql_query( $sql ) ) ) { ! mx_message_die( GENERAL_ERROR, 'Could not obtain menu navigation configuration', '', __LINE__, __FILE__, $sql ); } - $is_auth_ary = array(); $mx_show_cat = false; - - $menu_nav_config = $db->sql_fetchrowset( $result ); - - for( $row_count = 0; $row_count < count( $menu_nav_config ); $row_count++ ) - { - $menu_id = $menu_nav_config[$row_count][menu_id]; - - // Find if user is allowed for view - - $is_auth_ary = menu_auth( AUTH_VIEW, $menu_id , $userdata, $menu_nav_config[$row_count], $menu_nav_config[$row_count]['auth_view_group'] ); - if ( $is_auth_ary[auth_view] ) - { - - if ( !$mx_show_cat ) - { - $template->assign_block_vars( "catrow", array( "CAT_ID" => intval( $cat_id ), - "BLOCK_ID" => intval( $block_id ), - "CATEGORY" => $catt, - "U_URL" => append_sid( PORTAL_URL . 'index.' . $phpEx . '?block_id=' . $block_id ), - "U_CAT_ICON" => $cat_icon, - "U_CAT_NAV" => $cat_nav_icon_url, - "U_URL_SHOW" => $cat_url, - "DESCRIPTION" => $cat_desc - ) ); - // Generate the fold/unfold categories switches - if ( ( $HTTP_COOKIE_VARS['phpbbCategory_' . $block_id . $cat_id] ) != '' ) - { - $cat_on = $HTTP_COOKIE_VARS['phpbbCategory_' . $block_id . $cat_id]; - } - else - { - $cat_on = $menu_cat_config[$catrow_count]['cat_show'] == 1; - } - - if ( $cat_on ) - { - $template->assign_block_vars( 'catrow.switch_cat_on', array() ); - } - else - { - $template->assign_block_vars( 'catrow.switch_cat_off', array() ); - } - $mx_show_cat = true; - } - - $row_color = ( !( $row_count % 2 ) ) ? $theme['td_color1'] : $theme['td_color2']; - $row_class = ( !( $row_count % 2 ) ) ? $theme['td_class1'] : $theme['td_class2']; ! $action = $menu_nav_config[$row_count][menu_name]; ! $action = ( !empty( $lang[$action] ) ? $lang[$action] : $action ); ! $desc = $menu_nav_config[$row_count][menu_desc]; ! $desc = ( !empty( $lang[$desc] ) ? $lang[$desc] : $desc ); ! $bbcode_uid = $menu_nav_config[$row_count]['bbcode_uid']; ! $action = mx_decode( $action, $bbcode_uid ) ; ! if ( $menu_page_sync ) { ! $style = ( $menu_nav_config[$row_count][block_id] == $HTTP_GET_VARS['dynamic_block'] ) ? 'cattitle': ( ( $menu_nav_config[$row_count][block_id] == 0 && $menu_nav_config[$row_count][page_id] == $page_id ) ? 'cattitle': 'genmed' ); } else { ! $style = 'genmed'; } ! $icon_tmp = ( file_exists( $mx_root_path . TEMPLATE_ROOT_PATH . 'images/menu_icons/' . $menu_nav_config[$row_count][menu_icon] ) ? $menu_nav_config[$row_count][menu_icon] : 'update.gif' ); ! ! $icon_url_hot = str_replace( '.gif', '_hot.gif', 'menu_icons/' . $icon_tmp ); ! if ( file_exists( $mx_root_path . TEMPLATE_ROOT_PATH . 'images/' . $icon_url_hot ) ) ! { ! $icon_url = ( $style == 'cattitle' ) ? $icon_url_hot : 'menu_icons/' . $icon_tmp; ! } ! else ! { ! $icon_url = 'menu_icons/' . $icon_tmp ; ! } ! $menu_icon = ( !empty( $menu_nav_config[$row_count][menu_icon] ) && $menu_nav_config[$row_count][menu_icon] != 'none' ) ? '<img border="0" align="absmiddle" src="' . PORTAL_URL . TEMPLATE_ROOT_PATH . 'images/' . $icon_url . '" alt="' . $desc . '" /> ' : ""; ! $temp_menu_url = substr_count( $menu_nav_config[$row_count][menu_links], "http://" ) == 0 ? PORTAL_URL . $menu_nav_config[$row_count][menu_links] : $menu_nav_config[$row_count][menu_links]; ! ! if ( $menu_nav_config[$row_count][page_id] != 0 && $menu_nav_config[$row_count][block_id] == 0 && $menu_nav_config[$row_count][link_target] != 2 ) ! { ! $menu_link = append_sid( 'index.php?page=' . $menu_nav_config[$row_count][page_id] ) ; ! } ! else if ( $menu_nav_config[$row_count][page_id] != 0 && $menu_nav_config[$row_count][link_target] == 2 ) ! { ! $menu_link = append_sid( 'index.php?page=' . $menu_nav_config[$row_count][page_id] . '&' . $menu_nav_config[$row_count][menu_links] ) ; ! } ! else if ( $menu_nav_config[$row_count][link_target] == 2 ) ! { ! $menu_link = append_sid( 'index.php?page=' . $page_id . '&' . $menu_nav_config[$row_count][menu_links] ) ; ! } ! else if ( $menu_nav_config[$row_count][menu_links] != '' ) ! { ! $menu_link = $temp_menu_url ; ! } ! else if ( $menu_nav_config[$row_count][page_id] == 0 && $menu_nav_config[$row_count][block_id] != 0 ) ! { ! $menu_link = append_sid( 'index.php?page=' . $page_id . '&dynamic_block=' . $menu_nav_config[$row_count][block_id] ) ; ! } ! else if ( $menu_nav_config[$row_count][page_id] != 0 && $menu_nav_config[$row_count][block_id] != 0 ) ! { ! $menu_link = append_sid( 'index.php?page=' . $menu_nav_config[$row_count][page_id] . '&dynamic_block=' . $menu_nav_config[$row_count][block_id] ) ; ! } ! else ! { ! $sql = "SELECT module_path, function_file ! FROM " . FUNCTION_TABLE . " fnc, ! " . MODULE_TABLE . " mdl ! WHERE fnc.function_id = " . $menu_nav_config[$row_count][function_id] . " ! AND fnc.module_id = mdl.module_id"; ! if ( !$result = $db->sql_query( $sql ) ) ! { ! mx_message_die( GENERAL_ERROR, "Could not query modules information", "", __LINE__, __FILE__, $sql ); ! } ! $row = $db->sql_fetchrow( $result ); ! $menu_link = append_sid( $row['module_path'] . $row['function_file'] ) ; ! } ! $link_target = ( $menu_nav_config[$row_count][link_target] == 0 || $menu_nav_config[$row_count][link_target] == 2 ) ? '' : '_blank'; ! $template->assign_block_vars( "catrow.modulerow", array( "ROW_COLOR" => "#" . $row_color, ! "ROW_CLASS" => $row_class, ! "MENU_NAME" => $action, ! "MENU_STYLE" => $style, ! "MENU_DESC" => $desc, ! "U_MENU_MODULE" => $menu_link, ! "U_LINK_TARGET" => $link_target, ! "U_MENU_ICON" => $menu_icon ! ) ); } } } ! $template->pparse( "body" ); ?> \ No newline at end of file --- 136,286 ---- $cat_target = ( $menu_cat_config[$catrow_count]['cat_target'] == 0 ) ? '' : '_blank'; ! $cat_url_tmp = append_sid(PORTAL_URL . 'index.php?page=' . $menu_cat_config[$catrow_count]['cat_url']); $catt = ( $menu_cat_config[$catrow_count]['cat_url'] != 0 ) ? '<a class="genmed" href="' . $cat_url_tmp . '" target="' . $cat_target . '" /><span class="genmed">' . $cat . '</span></a>' : $cat; ! $sql = "SELECT * ! FROM " . MENU_NAV_TABLE . " ! WHERE cat_id = " . $cat_id . " ! ORDER BY menu_order, menu_id"; ! if ( !($result = $db->sql_query($sql)) ) { ! mx_message_die(GENERAL_ERROR, 'Could not obtain menu navigation configuration', '', __LINE__, __FILE__, $sql); } $mx_show_cat = false; ! $menu_nav_config = $db->sql_fetchrowset($result); ! for( $row_count = 0; $row_count < count($menu_nav_config); $row_count++ ) ! { ! $menu_id = $menu_nav_config[$row_count]['menu_id']; ! // ! // Find if user is allowed for view ! // ! $is_auth_ary = menu_auth(AUTH_VIEW, $menu_id, $userdata, $menu_nav_config[$row_count], $menu_nav_config[$row_count]['auth_view_group']); ! if ( !$is_auth_ary['auth_view'] ) ! { ! continue; ! } ! if ( !$mx_show_cat ) ! { ! $template->assign_block_vars('catrow', array( ! 'CAT_ID' => intval($cat_id), ! 'BLOCK_ID' => intval($block_id), ! 'CATEGORY' => $catt, ! 'U_URL' => append_sid(PORTAL_URL . 'index.' . $phpEx . '?block_id=' . $block_id), ! 'U_CAT_ICON' => $cat_icon, ! 'U_CAT_NAV' => $cat_nav_icon_url, ! 'U_URL_SHOW' => $cat_url, ! 'DESCRIPTION' => $cat_desc ! )); ! ! // Generate the fold/unfold categories switches ! if ( !empty($HTTP_COOKIE_VARS['phpbbCategory_' . $block_id . $cat_id]) ) { ! $cat_on = $HTTP_COOKIE_VARS['phpbbCategory_' . $block_id . $cat_id]; } else { ! $cat_on = ( $menu_cat_config[$catrow_count]['cat_show'] == 1 ); } ! $template->assign_block_vars('catrow.switch_cat_' . ( $cat_on ? 'on' : 'off' ), array()); ! $mx_show_cat = true; ! } ! $row_color = ( !( $row_count % 2 ) ) ? $theme['td_color1'] : $theme['td_color2']; ! $row_class = ( !( $row_count % 2 ) ) ? $theme['td_class1'] : $theme['td_class2']; ! $action = $menu_nav_config[$row_count]['menu_name']; ! $action = ( !empty($lang[$action]) ? $lang[$action] : $action ); ! $desc = $menu_nav_config[$row_count]['menu_desc']; ! $desc = ( !empty($lang[$desc]) ? $lang[$desc] : $desc ); ! $bbcode_uid = $menu_nav_config[$row_count]['bbcode_uid']; ! $action = mx_decode($action, $bbcode_uid); ! if ( $menu_page_sync ) ! { ! $style = ( $menu_nav_config[$row_count]['block_id'] == $HTTP_GET_VARS['dynamic_block'] ) ? 'cattitle' : ( ( $menu_nav_config[$row_count]['block_id'] == 0 && $menu_nav_config[$row_count]['page_id'] == $page_id ) ? 'cattitle' : 'genmed' ); ! } ! else ! { ! $style = 'genmed'; ! } ! $icon_tmp = ( file_exists($mx_root_path . TEMPLATE_ROOT_PATH . 'images/menu_icons/' . $menu_nav_config[$row_count]['menu_icon']) ? $menu_nav_config[$row_count]['menu_icon'] : 'update.gif' ); ! $icon_url_hot = str_replace('.gif', '_hot.gif', 'menu_icons/' . $icon_tmp); ! ! if ( file_exists($mx_root_path . TEMPLATE_ROOT_PATH . 'images/' . $icon_url_hot) ) ! { ! $icon_url = ( $style == 'cattitle' ) ? $icon_url_hot : 'menu_icons/' . $icon_tmp; ! } ! else ! { ! $icon_url = 'menu_icons/' . $icon_tmp; ! } ! ! $menu_icon = ( !empty($menu_nav_config[$row_count]['menu_icon']) && $menu_nav_config[$row_count]['menu_icon'] != 'none' ) ? '<img border="0" align="absmiddle" src="' . PORTAL_URL . TEMPLATE_ROOT_PATH . 'images/' . $icon_url . '" alt="' . $desc . '" /> ' : ''; ! ! if ( $menu_nav_config[$row_count]['page_id'] != 0 && $menu_nav_config[$row_count]['block_id'] == 0 && $menu_nav_config[$row_count]['link_target'] != 2 ) ! { ! $menu_link = append_sid(PORTAL_URL . 'index.php?page=' . $menu_nav_config[$row_count]['page_id']); } + else if ( $menu_nav_config[$row_count]['page_id'] != 0 && $menu_nav_config[$row_count]['link_target'] == 2 ) + { + $menu_link = append_sid(PORTAL_URL . 'index.php?page=' . $menu_nav_config[$row_count]['page_id'] . '&' . $menu_nav_config[$row_count]['menu_links']); + } + else if ( $menu_nav_config[$row_count]['link_target'] == 2 ) + { + $menu_link = append_sid(PORTAL_URL . 'index.php?page=' . $page_id . '&' . $menu_nav_config[$row_count]['menu_links']); + } + else if ( $menu_nav_config[$row_count]['menu_links'] != '' ) + { + $menu_link = ( substr_count($menu_nav_config[$row_count]['menu_links'], 'http://') == 0 ? PORTAL_URL . $menu_nav_config[$row_count]['menu_links'] : $menu_nav_config[$row_count]['menu_links'] ); + } + else if ( $menu_nav_config[$row_count]['page_id'] == 0 && $menu_nav_config[$row_count]['block_id'] != 0 ) + { + $menu_link = append_sid(PORTAL_URL . 'index.php?page=' . $page_id . '&dynamic_block=' . $menu_nav_config[$row_count]['block_id']); + } + else if ( $menu_nav_config[$row_count]['page_id'] != 0 && $menu_nav_config[$row_count]['block_id'] != 0 ) + { + $menu_link = append_sid(PORTAL_URL . 'index.php?page=' . $menu_nav_config[$row_count]['page_id'] . '&dynamic_block=' . $menu_nav_config[$row_count]['block_id']); + } + else + { + $sql = "SELECT module_path, function_file + FROM " . FUNCTION_TABLE . " fnc, + " . MODULE_TABLE . " mdl + WHERE fnc.function_id = " . $menu_nav_config[$row_count]['function_id'] . " + AND fnc.module_id = mdl.module_id"; + if ( !($result = $db->sql_query($sql)) ) + { + mx_message_die(GENERAL_ERROR, "Could not query modules information", '', __LINE__, __FILE__, $sql); + } + $row = $db->sql_fetchrow($result); + $menu_link = append_sid(PORTAL_URL . $row['module_path'] . $row['function_file']); + } + + $link_target = ( $menu_nav_config[$row_count]['link_target'] == 0 || $menu_nav_config[$row_count]['link_target'] == 2 ) ? '' : '_blank'; + + $template->assign_block_vars('catrow.modulerow', array( + 'ROW_COLOR' => '#' . $row_color, + 'ROW_CLASS' => $row_class, + 'MENU_NAME' => $action, + 'MENU_STYLE' => $style, + 'MENU_DESC' => $desc, + 'U_MENU_MODULE' => $menu_link, + 'U_LINK_TARGET' => $link_target, + 'U_MENU_ICON' => $menu_icon + )); } } ! $template->pparse('body'); ?> \ No newline at end of file |
|
From: Markus P. <mar...@us...> - 2005-04-19 19:59:42
|
Update of /cvsroot/mxbb/core In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv31885 Modified Files: index.php Log Message: Fixed some named array with non-quoted indexes and code layout. Added use of new mx_request_vars class. Index: index.php =================================================================== RCS file: /cvsroot/mxbb/core/index.php,v retrieving revision 1.32 retrieving revision 1.33 diff -C2 -d -r1.32 -r1.33 *** index.php 19 Apr 2005 13:51:54 -0000 1.32 --- index.php 19 Apr 2005 19:59:32 -0000 1.33 *************** *** 32,45 **** $view_page = false; // Page selector ! $page_id = $mx_request_vars->request('page', MX_TYPE_INT, 1); // Start session management ! $userdata = session_pagestart($user_ip, - ( 1000 + $page_id )); mx_init_userprefs($userdata); - // End session management if ( $mx_request_vars->is_request('mx_copy') ) --- 32,46 ---- $view_page = false; + // // Page selector ! // $page_id = $mx_request_vars->request('page', MX_TYPE_INT, 1); + // // Start session management ! // $userdata = session_pagestart($user_ip, - ( 1000 + $page_id )); mx_init_userprefs($userdata); if ( $mx_request_vars->is_request('mx_copy') ) *************** *** 48,54 **** } // Load page vars // Load http_session variables if populated, else consult db and populate http_session ! $mx_session_time = isset($HTTP_SESSION_VARS['mx_session_recached']) ? $HTTP_SESSION_VARS['mx_session_recached'] : $userdata['session_start']; if ( empty($HTTP_SESSION_VARS['mx_pages']['page_' . $page_id]) || $portal_config['portal_recached'] > $mx_session_time ) --- 49,56 ---- } + // // Load page vars // Load http_session variables if populated, else consult db and populate http_session ! // $mx_session_time = isset($HTTP_SESSION_VARS['mx_session_recached']) ? $HTTP_SESSION_VARS['mx_session_recached'] : $userdata['session_start']; if ( empty($HTTP_SESSION_VARS['mx_pages']['page_' . $page_id]) || $portal_config['portal_recached'] > $mx_session_time ) *************** *** 63,68 **** } // Now use the session data ! $page_row = $HTTP_SESSION_VARS['mx_pages']['page_' . $page_id]['page_info']; --- 65,71 ---- } + // // Now use the session data ! // $page_row = $HTTP_SESSION_VARS['mx_pages']['page_' . $page_id]['page_info']; *************** *** 77,81 **** --- 80,86 ---- $page_ov_header = $page_row['page_header']; + // // Page auth + // $is_auth_ary = page_auth(AUTH_VIEW, $userdata, $page_row['page_auth_view'], $page_row['page_auth_view_group']); *************** *** 90,99 **** } // Output header ! include($mx_root_path . 'includes/page_header.' . $phpEx); // Initialize template ! $layouttemplate = new mx_Template($template->root, $board_config, $db); --- 95,106 ---- } + // // Output header ! // include($mx_root_path . 'includes/page_header.' . $phpEx); + // // Initialize template ! // $layouttemplate = new mx_Template($template->root, $board_config, $db); *************** *** 102,107 **** ); // Generate the fold/unfold menu navigation switches (cookie based) ! if ( !empty($HTTP_COOKIE_VARS['phpbbEdit_Blocks']) ) { --- 109,115 ---- ); + // // Generate the fold/unfold menu navigation switches (cookie based) ! // if ( !empty($HTTP_COOKIE_VARS['phpbbEdit_Blocks']) ) { *************** *** 120,125 **** // ------------------------------------------------------------------------------------------------------------ // Page columns ! for( $column = 0; $column < $total_column; $column++ ) { --- 128,134 ---- // ------------------------------------------------------------------------------------------------------------ + // // Page columns ! // for( $column = 0; $column < $total_column; $column++ ) { *************** *** 147,152 **** } // Pass column data ! $layouttemplate->assign_block_vars('layout_column', array( 'COL_CLASS' => $colclass, --- 156,162 ---- } + // // Pass column data ! // $layouttemplate->assign_block_vars('layout_column', array( 'COL_CLASS' => $colclass, *************** *** 155,331 **** $column_contents = array(); // Page blocks ! $show_edit_blocks_icon = false; for( $block = 0; $block < $total_block; $block++ ) { // Validate this block is really visible and exists for the column ! if ( $column_rows[$column]['column_id'] == $block_rows[$block]['column_id'] ) ! { ! $block_id = $mx_block_id = $block_rows[$block]['block_id']; ! $block_file = $block_rows[$block]['function_file']; ! $dynamic_main_block_id = ''; ! ! // Block view auth ----------------------------------------------------------------------------------------------------- ! ! $is_auth_ary = block_auth(AUTH_VIEW, $mx_block_id, $userdata, $block_rows[$block]['auth_view'], $block_rows[$block]['auth_view_group']); ! ! if ( ($is_auth_ary['auth_view'] && $block_rows[$block]['show_block'] == 1) || $is_auth_ary['auth_mod'] ) ! { ! //$layouttemplate->assign_block_vars('layoutcol', array()); ! $template = new mx_Template($template->root, $board_config, $db); ! $module_root_path = $block_rows[$block]['module_path']; ! $title_class = $block_rows[$block]['function_file'] != 'mx_multiple_blocks.php' ? 'mxthHead' : 'mxthHead_none'; ! ob_start(); ! include($module_root_path . $block_file); ! $column_contents[$column] = ob_get_contents(); ! ob_end_clean(); ! // Pass block data ! if ( $block_rows[$block]['show_block'] == 1 || $is_auth_ary['auth_mod'] ) ! { ! $layouttemplate->assign_block_vars('layout_column.blocks', array( ! 'BLOCK' => $column_contents[$column], ! 'BLOCK_SIZE' => ( !empty($block_size) ? $block_size : '100%' ) ! )); ! // Switch: graphical block borders ! if ( !empty($page_row['page_graph_border']) ) ! { ! if ( file_exists($mx_root_path . TEMPLATE_ROOT_PATH . 'images/' . $page_row['page_graph_border'] . '1-1.gif') ) ! { ! $layouttemplate->assign_block_vars('layout_column.blocks.graph_border', array( ! 'TEMPLATE_ROOT_PATH' => TEMPLATE_ROOT_PATH, ! 'PREFIX' => $page_row['page_graph_border'] ! )); ! } ! } ! if ( $block_rows[$block]['show_stats'] == 1 && !empty($block_rows[$block]['block_time']) && !empty($block_rows[$block]['block_editor_id']) ) { ! $editor_name_tmp = get_userdata($block_rows[$block]['block_editor_id']); ! $editor_name = $editor_name_tmp['username']; ! $edit_time = create_date($board_config['default_dateformat'], $block_rows[$block]['block_time'], $board_config['board_timezone']); ! ! $layouttemplate->assign_block_vars('layout_column.blocks.block_stats', array( ! 'L_BLOCK_UPDATED' => $lang['Block_updated_by'], ! 'EDITOR_NAME' => $editor_name, ! 'EDIT_TIME' => $edit_time )); } ! else ! { ! $layouttemplate->assign_block_vars('layout_column.blocks.no_stats', array()); ! } } ! } // End View auth ! // Block edit auth --------------------------------------------------------------------------------- ! $mx_block_edit = false; ! ! $is_auth_ary = block_auth(AUTH_EDIT, $mx_block_id , $userdata, $block_rows[$block]['auth_edit'], $block_rows[$block]['auth_edit_group']); ! ! if ( ( ($is_auth_ary['auth_edit'] && $block_rows[$block]['show_block'] == 1 ) || $is_auth_ary['auth_mod']) ) ! { ! $show_edit_blocks_icon = true; ! $mx_block_edit = true; ! // Define some hidden Edit Block parameters ! $s_hidden_fields = '<input type="hidden" name="sid" value="' . $userdata['session_id'] . '" />'; ! $s_hidden_fields .= '<input type="hidden" name="portalpage" value="' . $page_id . '" />'; ! $s_hidden_fields .= '<input type="hidden" name="mode" value="setting" />'; ! $s_hidden_fields .= '<input type="hidden" name="f" value="' . intval($HTTP_GET_VARS['f']) . '" />'; ! $s_hidden_fields .= '<input type="hidden" name="t" value="' . intval($HTTP_GET_VARS['t']) . '" />'; ! $s_hidden_fields .= '<input type="hidden" name="p" value="' . intval($HTTP_GET_VARS['p']) . '" />'; ! // Switch between different block types ! $block_edit_img = ( ( $block_file == 'mx_multiple_blocks.php' ) ? 'block_edit_split.gif' : ( $block_file == 'mx_textblock_blog.php' ? 'block_edit_admin.gif' : 'block_edit.gif' ) ) ; ! $split_admin_file = !empty($block_rows[$block]['function_admin']) ? $block_rows[$block]['function_admin'] : 'admin/admin_mx_block.php'; ! // Dynamic Block Itself ! if ( !empty($dynamic_main_block_id) ) ! { ! $is_dynamic_auth_ary = block_auth(AUTH_EDIT, $dynamic_main_block_id , $userdata, $dynamic_block_config[$dynamic_main_block_id]['auth_edit'], $dynamic_block_config[$dynamic_main_block_id]['auth_edit_group']); ! ! if ( ($is_dynamic_auth_ary['auth_edit'] || $is_dynamic_auth_ary['auth_mod']) ) ! { ! $block_desc = !empty($dynamic_block_config[$dynamic_main_block_id]['block_desc']) ? ' (' . $dynamic_block_config[$dynamic_main_block_id]['block_desc'] . ')' : ''; ! $edit_url = append_sid($mx_root_path . "admin/admin_mx_block.php?sid=" . $userdata['session_id']); ! $edit_img = '<input type="image" class ="editblock" src="' . PORTAL_URL . TEMPLATE_ROOT_PATH . 'images/block_icons/' . 'block_edit_admin.gif' . '" alt="' . $lang['Block_Edit'] . $block_rows[$block]['block_id'] . '" title="' . $lang['Block_Edit'] . ' :: ' . $dynamic_block_config[$dynamic_main_block_id]['block_title'] . $block_desc . '">'; ! $s_hidden_fields .= '<input type="hidden" name="block_id" value="' . $dynamic_main_block_id . '" />'; ! $layouttemplate->assign_block_vars('layout_column.blocks.edit', array( ! 'BLOCK_SIZE' => ( !empty($block_size) ? $block_size : '100%' ), ! 'L_TITLE' => $title, ! 'L_DESC' => $b_description, ! 'EDIT_ACTION' => $edit_url, ! 'EDIT_IMG' => $edit_img, ! 'TITLECLASS' => $title_class, ! 'S_HIDDEN_FORM_FIELDS' => $s_hidden_fields ! )); ! $layouttemplate->assign_block_vars('layout_column.blocks.edit.switch_edit_' . ( $edit_on ? 'on' : 'off' ), array()); ! } } ! $block_desc = !empty($block_rows[$block]['block_desc']) ? ' (' . $block_rows[$block]['block_desc'] . ')' : ''; ! $edit_url = append_sid($mx_root_path . $split_admin_file . "?sid=" . $userdata['session_id']); ! $edit_img = '<input type="image" class ="editblock" src="' . PORTAL_URL . TEMPLATE_ROOT_PATH . 'images/block_icons/' . $block_edit_img . '" alt="' . $lang['Block_Edit'] . ' :: ' . $block_rows[$block]['block_title'] . $block_desc . '" title="' . $lang['Block_Edit'] . ' :: ' . $block_rows[$block]['block_title'] . $block_desc . '">'; ! ! $s_hidden_fields .= '<input type="hidden" name="block_id" value="' . $mx_block_id . '" />'; ! $layouttemplate->assign_block_vars('layout_column.blocks.edit', array( ! 'BLOCK_SIZE' => ( !empty($block_size) ? $block_size : '100%' ), ! 'L_TITLE' => $title, ! 'L_DESC' => $b_description, ! 'EDIT_ACTION' => $edit_url, ! 'EDIT_IMG' => $edit_img, ! 'TITLECLASS' => $title_class, ! 'S_HIDDEN_FORM_FIELDS' => $s_hidden_fields ! )); ! // Is the Block hidden ? ! if ( $block_rows[$block]['show_block'] == 0 ) ! { ! $hidden_img = '<img src="' . PORTAL_URL . TEMPLATE_ROOT_PATH . 'images/block_icons/block_hidden.gif" alt="' . $lang['Hidden_block'] . '">'; ! $layouttemplate->assign_block_vars('layout_column.blocks.edit.hidden_block', array( ! 'HIDDEN_BLOCK' => $hidden_img ! )); ! } ! // Switch: Edit Block ! $layouttemplate->assign_block_vars('layout_column.blocks.edit.switch_edit_' . ( $edit_on ? 'on' : 'off' ), array()); ! } // End Edit auth ! // Switch: show block header ------------------- ! if ( $block_rows[$block]['show_block'] == 1 && ( $mx_block_edit || $block_rows[$block]['show_title'] == 1 ) || $is_auth_ary['auth_mod'] ) { ! $layouttemplate->assign_block_vars('layout_column.blocks.block_header', array()); ! ! // Switch: show title ------------------- ! if ( $block_rows[$block]['show_title'] == 1 || $is_auth_ary['auth_mod'] ) ! { ! $this_block_title = $block_rows[$block]['show_title'] == 0 && $is_auth_ary['auth_mod'] ? '(' . $block_rows[$block]['block_title'] . ')' : $block_rows[$block]['block_title']; ! $layouttemplate->assign_block_vars('layout_column.blocks.show_title', array( ! 'L_TITLE' => $this_block_title, ! 'TITLECLASS' => $title_class ! )); ! } } - } } // for ... blocks } // for ... column --- 165,354 ---- $column_contents = array(); + // // Page blocks ! // $show_edit_blocks_icon = false; for( $block = 0; $block < $total_block; $block++ ) { + // // Validate this block is really visible and exists for the column + // + if ( $column_rows[$column]['column_id'] != $block_rows[$block]['column_id'] ) + { + continue; + } ! $block_id = $mx_block_id = $block_rows[$block]['block_id']; ! $block_file = $block_rows[$block]['function_file']; ! $dynamic_main_block_id = ''; ! // Block view auth ----------------------------------------------------------------------------------------------------- ! $is_auth_ary = block_auth(AUTH_VIEW, $mx_block_id, $userdata, $block_rows[$block]['auth_view'], $block_rows[$block]['auth_view_group']); ! ! if ( ($is_auth_ary['auth_view'] && $block_rows[$block]['show_block'] == 1) || $is_auth_ary['auth_mod'] ) ! { ! //$layouttemplate->assign_block_vars('layoutcol', array()); ! $template = new mx_Template($template->root, $board_config, $db); ! $module_root_path = $block_rows[$block]['module_path']; ! $title_class = ( $block_rows[$block]['function_file'] != 'mx_multiple_blocks.php' ? 'mxthHead' : 'mxthHead_none' ); ! ob_start(); ! include($module_root_path . $block_file); ! $column_contents[$column] = ob_get_contents(); ! ob_end_clean(); ! // ! // Pass block data ! // ! if ( $block_rows[$block]['show_block'] == 1 || $is_auth_ary['auth_mod'] ) ! { ! $layouttemplate->assign_block_vars('layout_column.blocks', array( ! 'BLOCK' => $column_contents[$column], ! 'BLOCK_SIZE' => ( !empty($block_size) ? $block_size : '100%' ) ! )); ! // ! // Switch: graphical block borders ! // ! if ( !empty($page_row['page_graph_border']) ) ! { ! if ( file_exists($mx_root_path . TEMPLATE_ROOT_PATH . 'images/' . $page_row['page_graph_border'] . '1-1.gif') ) { ! $layouttemplate->assign_block_vars('layout_column.blocks.graph_border', array( ! 'TEMPLATE_ROOT_PATH' => TEMPLATE_ROOT_PATH, ! 'PREFIX' => $page_row['page_graph_border'] )); } ! } ! ! if ( $block_rows[$block]['show_stats'] == 1 && !empty($block_rows[$block]['block_time']) && !empty($block_rows[$block]['block_editor_id']) ) ! { ! $editor_name_tmp = get_userdata($block_rows[$block]['block_editor_id']); ! $editor_name = $editor_name_tmp['username']; ! $edit_time = create_date($board_config['default_dateformat'], $block_rows[$block]['block_time'], $board_config['board_timezone']); ! ! $layouttemplate->assign_block_vars('layout_column.blocks.block_stats', array( ! 'L_BLOCK_UPDATED' => $lang['Block_updated_by'], ! 'EDITOR_NAME' => $editor_name, ! 'EDIT_TIME' => $edit_time ! )); } ! else ! { ! $layouttemplate->assign_block_vars('layout_column.blocks.no_stats', array()); ! } ! } ! } // End View auth ! // Block edit auth --------------------------------------------------------------------------------- ! $mx_block_edit = false; ! $is_auth_ary = block_auth(AUTH_EDIT, $mx_block_id, $userdata, $block_rows[$block]['auth_edit'], $block_rows[$block]['auth_edit_group']); ! ! if ( ( ($is_auth_ary['auth_edit'] && $block_rows[$block]['show_block'] == 1 ) || $is_auth_ary['auth_mod']) ) ! { ! $show_edit_blocks_icon = true; ! $mx_block_edit = true; ! // Define some hidden Edit Block parameters ! $s_hidden_fields = '<input type="hidden" name="sid" value="' . $userdata['session_id'] . '" />'; ! $s_hidden_fields .= '<input type="hidden" name="portalpage" value="' . $page_id . '" />'; ! $s_hidden_fields .= '<input type="hidden" name="mode" value="setting" />'; ! $s_hidden_fields .= '<input type="hidden" name="f" value="' . intval($HTTP_GET_VARS['f']) . '" />'; ! $s_hidden_fields .= '<input type="hidden" name="t" value="' . intval($HTTP_GET_VARS['t']) . '" />'; ! $s_hidden_fields .= '<input type="hidden" name="p" value="' . intval($HTTP_GET_VARS['p']) . '" />'; ! // ! // Switch between different block types ! // ! $block_edit_img = ( ( $block_file == 'mx_multiple_blocks.php' ) ? 'block_edit_split.gif' : ( $block_file == 'mx_textblock_blog.php' ? 'block_edit_admin.gif' : 'block_edit.gif' ) ) ; ! $split_admin_file = !empty($block_rows[$block]['function_admin']) ? $block_rows[$block]['function_admin'] : 'admin/admin_mx_block.php'; ! // ! // Dynamic Block Itself ! // ! if ( !empty($dynamic_main_block_id) ) ! { ! $is_dynamic_auth_ary = block_auth(AUTH_EDIT, $dynamic_main_block_id , $userdata, $dynamic_block_config[$dynamic_main_block_id]['auth_edit'], $dynamic_block_config[$dynamic_main_block_id]['auth_edit_group']); ! ! if ( ($is_dynamic_auth_ary['auth_edit'] || $is_dynamic_auth_ary['auth_mod']) ) ! { ! $block_desc = !empty($dynamic_block_config[$dynamic_main_block_id]['block_desc']) ? ' (' . $dynamic_block_config[$dynamic_main_block_id]['block_desc'] . ')' : ''; ! $edit_url = append_sid($mx_root_path . "admin/admin_mx_block.php?sid=" . $userdata['session_id']); ! $edit_img = '<input type="image" class ="editblock" src="' . PORTAL_URL . TEMPLATE_ROOT_PATH . 'images/block_icons/' . 'block_edit_admin.gif' . '" alt="' . $lang['Block_Edit'] . $block_rows[$block]['block_id'] . '" title="' . $lang['Block_Edit'] . ' :: ' . $dynamic_block_config[$dynamic_main_block_id]['block_title'] . $block_desc . '">'; ! $s_hidden_fields .= '<input type="hidden" name="block_id" value="' . $dynamic_main_block_id . '" />'; ! $layouttemplate->assign_block_vars('layout_column.blocks.edit', array( ! 'BLOCK_SIZE' => ( !empty($block_size) ? $block_size : '100%' ), ! 'L_TITLE' => $title, ! 'L_DESC' => $b_description, ! 'EDIT_ACTION' => $edit_url, ! 'EDIT_IMG' => $edit_img, ! 'TITLECLASS' => $title_class, ! 'S_HIDDEN_FORM_FIELDS' => $s_hidden_fields ! )); ! $layouttemplate->assign_block_vars('layout_column.blocks.edit.switch_edit_' . ( $edit_on ? 'on' : 'off' ), array()); } + } ! $block_desc = !empty($block_rows[$block]['block_desc']) ? ' (' . $block_rows[$block]['block_desc'] . ')' : ''; ! $edit_url = append_sid($mx_root_path . $split_admin_file . "?sid=" . $userdata['session_id']); ! $edit_img = '<input type="image" class ="editblock" src="' . PORTAL_URL . TEMPLATE_ROOT_PATH . 'images/block_icons/' . $block_edit_img . '" alt="' . $lang['Block_Edit'] . ' :: ' . $block_rows[$block]['block_title'] . $block_desc . '" title="' . $lang['Block_Edit'] . ' :: ' . $block_rows[$block]['block_title'] . $block_desc . '">'; ! $s_hidden_fields .= '<input type="hidden" name="block_id" value="' . $mx_block_id . '" />'; ! $layouttemplate->assign_block_vars('layout_column.blocks.edit', array( ! 'BLOCK_SIZE' => ( !empty($block_size) ? $block_size : '100%' ), ! 'L_TITLE' => $title, ! 'L_DESC' => $b_description, ! 'EDIT_ACTION' => $edit_url, ! 'EDIT_IMG' => $edit_img, ! 'TITLECLASS' => $title_class, ! 'S_HIDDEN_FORM_FIELDS' => $s_hidden_fields ! )); ! // ! // Is the Block hidden ? ! // ! if ( $block_rows[$block]['show_block'] == 0 ) ! { ! $hidden_img = '<img src="' . PORTAL_URL . TEMPLATE_ROOT_PATH . 'images/block_icons/block_hidden.gif" alt="' . $lang['Hidden_block'] . '">'; ! $layouttemplate->assign_block_vars('layout_column.blocks.edit.hidden_block', array( ! 'HIDDEN_BLOCK' => $hidden_img ! )); ! } ! // ! // Switch: Edit Block ! // ! $layouttemplate->assign_block_vars('layout_column.blocks.edit.switch_edit_' . ( $edit_on ? 'on' : 'off' ), array()); ! } // End Edit auth ! // Switch: show block header ------------------- ! if ( $block_rows[$block]['show_block'] == 1 && ( $mx_block_edit || $block_rows[$block]['show_title'] == 1 ) || $is_auth_ary['auth_mod'] ) ! { ! $layouttemplate->assign_block_vars('layout_column.blocks.block_header', array()); ! // Switch: show title ------------------- ! if ( $block_rows[$block]['show_title'] == 1 || $is_auth_ary['auth_mod'] ) { ! $this_block_title = $block_rows[$block]['show_title'] == 0 && $is_auth_ary['auth_mod'] ? '(' . $block_rows[$block]['block_title'] . ')' : $block_rows[$block]['block_title']; ! $layouttemplate->assign_block_vars('layout_column.blocks.show_title', array( ! 'L_TITLE' => $this_block_title, ! 'TITLECLASS' => $title_class ! )); } } + } // for ... blocks + } // for ... column |
|
From: Markus P. <mar...@us...> - 2005-04-19 18:29:27
|
Update of /cvsroot/mxbb/core/modules/mx_coreblocks/templates/subSilver In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv17461/templates/subSilver Modified Files: mx_menu_nav.tpl mx_menu_nav_horizontal.tpl mx_online.tpl mx_search_body.tpl mx_search_results.tpl mx_site_log.tpl Removed Files: mx_posting_smilies.tpl Log Message: Fixed some named array with non-quoted indexes and code layout. Added use of new mx_request_vars class. Index: mx_menu_nav.tpl =================================================================== RCS file: /cvsroot/mxbb/core/modules/mx_coreblocks/templates/subSilver/mx_menu_nav.tpl,v retrieving revision 1.8 retrieving revision 1.9 diff -C2 -d -r1.8 -r1.9 *** mx_menu_nav.tpl 18 Feb 2005 10:05:06 -0000 1.8 --- mx_menu_nav.tpl 19 Apr 2005 18:29:13 -0000 1.9 *************** *** 1,38 **** ! <table width="{BLOCK_SIZE}" cellpadding="4" cellspacing="0" border="0" class="forumline" > ! <!-- BEGIN catrow --> ! <tr> ! <td class="row2" height="10" align="center" width="10" > ! ! <!-- BEGIN switch_cat_on --> ! <span class="newsbutton" onClick="rollup_contract(this, 'phpbbCategory_{catrow.BLOCK_ID}{catrow.CAT_ID}', '{catrow.U_CAT_NAV}');"><img src="{catrow.U_CAT_NAV}contract.gif" border="0" /></span> ! <!-- END switch_cat_on --> ! <!-- BEGIN switch_cat_off --> ! <span class="newsbutton" onClick="rollup_contract(this, 'phpbbCategory_{catrow.BLOCK_ID}{catrow.CAT_ID}', '{catrow.U_CAT_NAV}');"><img src="{catrow.U_CAT_NAV}expand.gif" border="0" /></span> ! <!-- END switch_cat_off --> ! </td> <td class="row2" height="10" align="left" width="100%"> ! <span class="genmed"> ! <b>{catrow.CATEGORY}</b> ! </span> </td> </tr> ! <tr> ! <td class="row1" align="left" colspan="2"><span class="genmed">{catrow.DESCRIPTION}</span></td> </tr> ! <!-- BEGIN switch_cat_on --> ! <tbody id="phpbbCategory_{catrow.BLOCK_ID}{catrow.CAT_ID}" style="display: ;"> ! <!-- END switch_cat_on --> ! <!-- BEGIN switch_cat_off --> ! <tbody id="phpbbCategory_{catrow.BLOCK_ID}{catrow.CAT_ID}" style="display: none;"> ! <!-- END switch_cat_off --> ! <!-- BEGIN modulerow --> ! <tr> ! <td class="row1" valign="middle" height="10" align="left" colspan="2">{catrow.modulerow.U_MENU_ICON}<span class="{catrow.modulerow.MENU_STYLE}"> <a href="{catrow.modulerow.U_MENU_MODULE}" target="{catrow.modulerow.U_LINK_TARGET}" class="genmed" title="{catrow.modulerow.MENU_DESC}">{catrow.modulerow.MENU_NAME}</a></span></td> ! </tr> ! <!-- END modulerow --> </tbody> --- 1,34 ---- ! <table width="{BLOCK_SIZE}" cellpadding="4" cellspacing="0" border="0" class="forumline"> ! <!-- BEGIN catrow --> ! <tr> ! <td class="row2" height="10" align="center" width="10"> ! <!-- BEGIN switch_cat_on --> ! <span class="newsbutton" onClick="rollup_contract(this, 'phpbbCategory_{catrow.BLOCK_ID}{catrow.CAT_ID}', '{catrow.U_CAT_NAV}');"><img src="{catrow.U_CAT_NAV}contract.gif" border="0" /></span> ! <!-- END switch_cat_on --> ! <!-- BEGIN switch_cat_off --> ! <span class="newsbutton" onClick="rollup_contract(this, 'phpbbCategory_{catrow.BLOCK_ID}{catrow.CAT_ID}', '{catrow.U_CAT_NAV}');"><img src="{catrow.U_CAT_NAV}expand.gif" border="0" /></span> ! <!-- END switch_cat_off --> </td> <td class="row2" height="10" align="left" width="100%"> ! <span class="genmed"><b>{catrow.CATEGORY}</b></span> </td> </tr> ! <tr> ! <td class="row1" align="left" colspan="2"><span class="genmed">{catrow.DESCRIPTION}</span></td> </tr> ! <!-- BEGIN switch_cat_on --> ! <tbody id="phpbbCategory_{catrow.BLOCK_ID}{catrow.CAT_ID}" style="display: ;"> ! <!-- END switch_cat_on --> ! <!-- BEGIN switch_cat_off --> ! <tbody id="phpbbCategory_{catrow.BLOCK_ID}{catrow.CAT_ID}" style="display: none;"> ! <!-- END switch_cat_off --> ! <!-- BEGIN modulerow --> ! <tr> ! <td class="row1" valign="middle" height="10" align="left" colspan="2">{catrow.modulerow.U_MENU_ICON}<span class="{catrow.modulerow.MENU_STYLE}"> <a href="{catrow.modulerow.U_MENU_MODULE}" target="{catrow.modulerow.U_LINK_TARGET}" class="genmed" title="{catrow.modulerow.MENU_DESC}">{catrow.modulerow.MENU_NAME}</a></span></td> ! </tr> ! <!-- END modulerow --> </tbody> --- mx_posting_smilies.tpl DELETED --- Index: mx_search_results.tpl =================================================================== RCS file: /cvsroot/mxbb/core/modules/mx_coreblocks/templates/subSilver/mx_search_results.tpl,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** mx_search_results.tpl 6 Mar 2005 01:10:16 -0000 1.2 --- mx_search_results.tpl 19 Apr 2005 18:29:14 -0000 1.3 *************** *** 1,36 **** <table width="100%" cellspacing="2" cellpadding="2" border="0" align="center"> ! <tr> ! <td align="left" valign="bottom"><span class="maintitle">{L_SEARCH_MATCHES}</span><br /></td> ! </tr> </table> <table width="100%" cellspacing="2" cellpadding="2" border="0" align="center"> ! <tr> ! <td align="left"><span class="nav"><a href="{U_KB}" class="nav">{L_KB}</a></span></td> ! </tr> </table> <table width="100%" cellpadding="4" cellspacing="1" border="0" class="forumline" align="center"> ! <tr> ! <th align="left" class="thCornerL" nowrap="nowrap" width="30%"> {L_ARTICLE} </th> ! <th align="left" class="thHead" nowrap="nowrap"> {L_CATEGORY} </th> ! </tr> ! <!-- BEGIN searchresults --> ! <tr> ! <td class="row1"><span class="forumlink"><a href="{searchresults.U_VIEW_ARTICLE}" class="forumlink">{searchresults.ARTICLE_TITLE}</a></span><br /><span class="gen">{searchresults.ARTICLE_DESCRIPTION}</span></td> ! <td class="row2" align="left" valign="middle"><span class="name">{searchresults.ARTICLE_CATEGORY}</span></td> ! </tr> ! <!-- END searchresults --> ! <tr> ! <td class="catBottom" colspan="7" height="28" valign="middle"> </td> ! </tr> </table> <table width="100%" cellspacing="2" border="0" align="center" cellpadding="2"> ! <tr> ! <td align="left" valign="top"><span class="nav">{PAGE_NUMBER}</span></td> ! <td align="right" valign="top" nowrap="nowrap"><span class="nav">{PAGINATION}</span><br /><span class="gensmall">{S_TIMEZONE}</span></td> ! </tr> </table> - - --- 1,34 ---- <table width="100%" cellspacing="2" cellpadding="2" border="0" align="center"> ! <tr> ! <td align="left" valign="bottom"><span class="maintitle">{L_SEARCH_MATCHES}</span><br /></td> ! </tr> </table> <table width="100%" cellspacing="2" cellpadding="2" border="0" align="center"> ! <tr> ! <td align="left"><span class="nav"><a href="{U_KB}" class="nav">{L_KB}</a></span></td> ! </tr> </table> <table width="100%" cellpadding="4" cellspacing="1" border="0" class="forumline" align="center"> ! <tr> ! <th align="left" class="thCornerL" nowrap="nowrap" width="30%"> {L_ARTICLE} </th> ! <th align="left" class="thHead" nowrap="nowrap"> {L_CATEGORY} </th> ! </tr> ! <!-- BEGIN searchresults --> ! <tr> ! <td class="row1"><span class="forumlink"><a href="{searchresults.U_VIEW_ARTICLE}" class="forumlink">{searchresults.ARTICLE_TITLE}</a></span><br /><span class="gen">{searchresults.ARTICLE_DESCRIPTION}</span></td> ! <td class="row2" align="left" valign="middle"><span class="name">{searchresults.ARTICLE_CATEGORY}</span></td> ! </tr> ! <!-- END searchresults --> ! <tr> ! <td class="catBottom" colspan="2" height="28" valign="middle"> </td> ! </tr> </table> <table width="100%" cellspacing="2" border="0" align="center" cellpadding="2"> ! <tr> ! <td align="left" valign="top"><span class="nav">{PAGE_NUMBER}</span></td> ! <td align="right" valign="top" nowrap="nowrap"><span class="nav">{PAGINATION}</span><br /><span class="gensmall">{S_TIMEZONE}</span></td> ! </tr> </table> Index: mx_online.tpl =================================================================== RCS file: /cvsroot/mxbb/core/modules/mx_coreblocks/templates/subSilver/mx_online.tpl,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** mx_online.tpl 6 Mar 2005 01:10:16 -0000 1.4 --- mx_online.tpl 19 Apr 2005 18:29:14 -0000 1.5 *************** *** 1,10 **** <table width="{BLOCK_SIZE}" cellpadding="4" cellspacing="0" border="0" class="forumline"> ! <tr> ! <td class="row1" align="center" valign="middle" rowspan="2"><a href="{U_VIEWONLINE}" class="cattitle"><img src="{U_PHPBB_ROOT_PATH}{TEMPLATE_ROOT_PATH}images/whosonline.gif" alt="{L_WHO_IS_ONLINE}" border="0" /></a></td> ! <td class="row1" align="left" width="100%"><span class="gensmall">{TOTAL_POSTS}<br />{TOTAL_USERS}<br />{NEWEST_USER}</span> ! </td> ! </tr> ! <tr> ! <td class="row1" align="left"><span class="gensmall">{TOTAL_USERS_ONLINE} [ {L_WHOSONLINE_ADMIN} ] [ {L_WHOSONLINE_MOD} ]<br />{RECORD_USERS}<br />{LOGGED_IN_USER_LIST}</span></td> ! </tr> </table> --- 1,9 ---- <table width="{BLOCK_SIZE}" cellpadding="4" cellspacing="0" border="0" class="forumline"> ! <tr> ! <td class="row1" align="center" valign="middle" rowspan="2"><a href="{U_VIEWONLINE}" class="cattitle"><img src="{U_PHPBB_ROOT_PATH}{TEMPLATE_ROOT_PATH}images/whosonline.gif" alt="{L_WHO_IS_ONLINE}" border="0" /></a></td> ! <td class="row1" align="left" width="100%"><span class="gensmall">{TOTAL_POSTS}<br />{TOTAL_USERS}<br />{NEWEST_USER}</span></td> ! </tr> ! <tr> ! <td class="row1" align="left"><span class="gensmall">{TOTAL_USERS_ONLINE} [ {L_WHOSONLINE_ADMIN} ] [ {L_WHOSONLINE_MOD} ]<br />{RECORD_USERS}<br />{LOGGED_IN_USER_LIST}</span></td> ! </tr> </table> Index: mx_search_body.tpl =================================================================== RCS file: /cvsroot/mxbb/core/modules/mx_coreblocks/templates/subSilver/mx_search_body.tpl,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** mx_search_body.tpl 6 Mar 2005 01:10:16 -0000 1.2 --- mx_search_body.tpl 19 Apr 2005 18:29:14 -0000 1.3 *************** *** 1,4 **** ! <form action="{S_SEARCH_ACTION}" method="POST"><table width="100%" cellspacing="2" cellpadding="2" border="0" align="center"> ! <tr> <td align="left"><span class="nav"><a href="{U_KB}" class="nav">{L_KB}</a></span></td> </tr> --- 1,5 ---- ! <form action="{S_SEARCH_ACTION}" method="post"> ! <table width="100%" cellspacing="2" cellpadding="2" border="0" align="center"> ! <tr> <td align="left"><span class="nav"><a href="{U_KB}" class="nav">{L_KB}</a></span></td> </tr> *************** *** 6,17 **** <table class="forumline" width="100%" cellpadding="4" cellspacing="1" border="0"> ! <tr> <th class="thHead" colspan="4" height="25">{L_SEARCH_QUERY}</th> </tr> ! <tr> <td class="row1" colspan="2" width="50%"><span class="gen">{L_SEARCH_KEYWORDS}:</span><br /><span class="gensmall">{L_SEARCH_KEYWORDS_EXPLAIN}</span></td> <td class="row2" colspan="2" valign="top"><span class="genmed"><input type="text" style="width: 300px" class="post" name="search_keywords" size="30" /><br /><input type="radio" name="search_terms" value="any" checked="checked" /> {L_SEARCH_ANY_TERMS}<br /><input type="radio" name="search_terms" value="all" /> {L_SEARCH_ALL_TERMS}</span></td> </tr> ! <tr> <td class="catBottom" colspan="4" align="center" height="28">{S_HIDDEN_FIELDS}<input class="liteoption" type="submit" value="{S_SEARCH}" /></td> </tr> --- 7,18 ---- <table class="forumline" width="100%" cellpadding="4" cellspacing="1" border="0"> ! <tr> <th class="thHead" colspan="4" height="25">{L_SEARCH_QUERY}</th> </tr> ! <tr> <td class="row1" colspan="2" width="50%"><span class="gen">{L_SEARCH_KEYWORDS}:</span><br /><span class="gensmall">{L_SEARCH_KEYWORDS_EXPLAIN}</span></td> <td class="row2" colspan="2" valign="top"><span class="genmed"><input type="text" style="width: 300px" class="post" name="search_keywords" size="30" /><br /><input type="radio" name="search_terms" value="any" checked="checked" /> {L_SEARCH_ANY_TERMS}<br /><input type="radio" name="search_terms" value="all" /> {L_SEARCH_ALL_TERMS}</span></td> </tr> ! <tr> <td class="catBottom" colspan="4" align="center" height="28">{S_HIDDEN_FIELDS}<input class="liteoption" type="submit" value="{S_SEARCH}" /></td> </tr> *************** *** 19,26 **** <table width="100%" cellspacing="2" cellpadding="2" border="0" align="center"> ! <tr> <td align="right" valign="middle"><span class="gensmall">{S_TIMEZONE}</span></td> </tr> ! </table></form> ! ! --- 20,26 ---- <table width="100%" cellspacing="2" cellpadding="2" border="0" align="center"> ! <tr> <td align="right" valign="middle"><span class="gensmall">{S_TIMEZONE}</span></td> </tr> ! </table> ! </form> Index: mx_site_log.tpl =================================================================== RCS file: /cvsroot/mxbb/core/modules/mx_coreblocks/templates/subSilver/mx_site_log.tpl,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** mx_site_log.tpl 11 Feb 2005 22:07:07 -0000 1.1 --- mx_site_log.tpl 19 Apr 2005 18:29:14 -0000 1.2 *************** *** 1,32 **** <table width="{BLOCK_SIZE}" cellpadding="4" cellspacing="0" border="0" class="forumline"> ! <!-- BEGIN no_row --> ! <tr> <td class="row1" align="left" colspan="2">{no_row.L_NO_ITEMS}</td> </tr> ! <!-- END no_row --> ! <!-- BEGIN msg_row --> ! <tr> ! <td width="5%" class="row2" align="center"> ! <span class="cattitle"><img src="{U_PORTAL_ROOT_PATH}{TEMPLATE_ROOT_PATH}{msg_row.FOLDER_IMG}" width="19" height="18" alt="{msg_row.L_TOPIC_FOLDER_ALT}" title="{msg_row.L_TOPIC_FOLDER_ALT}" /></span> ! </td> <td class="row1" align="left"> <span class="gen"><b><a href="{msg_row.U_PAGE}" target="{U_TARGET}" class="genmed">{msg_row.LAST_PAGE}</a></b></span><br /> <span class="genmed">» <a href="{msg_row.U_BLOCK}" target="{U_TARGET}" class="genmed">{msg_row.LAST_BLOCK}</a></span><br /> ! <span class="gensmall"><i>{msg_row.EXTRA}</i>{msg_row.L_BLOCK_UPDATED}{msg_row.EDITOR} ({msg_row.EDIT_TIME}</span>) </td> </tr> ! <!-- END msg_row --> ! <tr valign="middle"> ! <!-- ! <td align="center" class="catBottom" height="28" colspan="2"> ! <a href="{U_URL_PREV}" class="cattitle"><img src="{U_PORTAL_ROOT_PATH}{TEMPLATE_ROOT_PATH}images/msg_prev.gif" border="0" width="19" height="18" alt="{L_MSG_PREV}" title="{L_MSG_PREV}" /></a> ! <a href="{U_URL_NEXT}" class="cattitle"><img src="{U_PORTAL_ROOT_PATH}{TEMPLATE_ROOT_PATH}images/msg_next.gif" border="0" width="19" height="18" alt="{L_MSG_NEXT}" title="{L_MSG_NEXT}" /></a> ! </td> ! </tr> ! --> ! <tr> <!-- <td align="center" valign="top"><span class="catBottom">{PAGE_NUMBER}</span></td> --> <td align="right" valign="top" nowrap="nowrap" colspan="2" class="catBottom"><span class="gensmall">{PAGINATION}</span></td> ! </tr> </table> - --- 1,31 ---- <table width="{BLOCK_SIZE}" cellpadding="4" cellspacing="0" border="0" class="forumline"> ! <!-- BEGIN no_row --> ! <tr> <td class="row1" align="left" colspan="2">{no_row.L_NO_ITEMS}</td> </tr> ! <!-- END no_row --> ! <!-- BEGIN msg_row --> ! <tr> ! <td width="5%" class="row2" align="center"> ! <span class="cattitle"><img src="{U_PORTAL_ROOT_PATH}{TEMPLATE_ROOT_PATH}{msg_row.FOLDER_IMG}" width="19" height="18" alt="{msg_row.L_TOPIC_FOLDER_ALT}" title="{msg_row.L_TOPIC_FOLDER_ALT}" /></span> ! </td> <td class="row1" align="left"> <span class="gen"><b><a href="{msg_row.U_PAGE}" target="{U_TARGET}" class="genmed">{msg_row.LAST_PAGE}</a></b></span><br /> <span class="genmed">» <a href="{msg_row.U_BLOCK}" target="{U_TARGET}" class="genmed">{msg_row.LAST_BLOCK}</a></span><br /> ! <span class="gensmall"><i>{msg_row.EXTRA}</i>{msg_row.L_BLOCK_UPDATED}{msg_row.EDITOR} ({msg_row.EDIT_TIME}</span>) </td> </tr> ! <!-- END msg_row --> ! <!-- ! <tr valign="middle"> ! <td align="center" class="catBottom" height="28" colspan="2"> ! <a href="{U_URL_PREV}" class="cattitle"><img src="{U_PORTAL_ROOT_PATH}{TEMPLATE_ROOT_PATH}images/msg_prev.gif" border="0" width="19" height="18" alt="{L_MSG_PREV}" title="{L_MSG_PREV}" /></a> ! <a href="{U_URL_NEXT}" class="cattitle"><img src="{U_PORTAL_ROOT_PATH}{TEMPLATE_ROOT_PATH}images/msg_next.gif" border="0" width="19" height="18" alt="{L_MSG_NEXT}" title="{L_MSG_NEXT}" /></a> ! </td> ! </tr> ! --> ! <tr> <!-- <td align="center" valign="top"><span class="catBottom">{PAGE_NUMBER}</span></td> --> <td align="right" valign="top" nowrap="nowrap" colspan="2" class="catBottom"><span class="gensmall">{PAGINATION}</span></td> ! </tr> </table> Index: mx_menu_nav_horizontal.tpl =================================================================== RCS file: /cvsroot/mxbb/core/modules/mx_coreblocks/templates/subSilver/mx_menu_nav_horizontal.tpl,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** mx_menu_nav_horizontal.tpl 18 Feb 2005 10:05:06 -0000 1.4 --- mx_menu_nav_horizontal.tpl 19 Apr 2005 18:29:14 -0000 1.5 *************** *** 1,45 **** ! <table width="{BLOCK_SIZE}" cellpadding="4" cellspacing="0" border="0" class="forumline" > ! <tr> ! <!-- BEGIN catrow --> ! <td class="row1" align="left" width="{CAT_WIDTH}" valign="top"> ! <table width="100%" cellpadding="0" cellspacing="0" border="0"> ! <tr> ! <td class="row2" height="18" width="20" align="center" valign="middle"> ! ! <!-- BEGIN switch_cat_on --> ! <span class="newsbutton" onClick="rollup_contract(this, 'phpbbCategory_{catrow.BLOCK_ID}{catrow.CAT_ID}', '{catrow.U_CAT_NAV}');"><img src="{catrow.U_CAT_NAV}contract.gif" border="0" /></span> ! <!-- END switch_cat_on --> ! <!-- BEGIN switch_cat_off --> ! <span class="newsbutton" onClick="rollup_contract(this, 'phpbbCategory_{catrow.BLOCK_ID}{catrow.CAT_ID}', '{catrow.U_CAT_NAV}');"><img src="{catrow.U_CAT_NAV}expand.gif" border="0" /></span> ! <!-- END switch_cat_off --> ! ! </td> ! <td class="row2" align="left" height="18" width="100%"> ! <span class="genmed"> ! <b> {catrow.CATEGORY}</b> ! </span></td> ! </tr> ! <tr> ! <td class="row1" align="left" colspan="2"><span class="genmed">{catrow.DESCRIPTION}</span></td> ! </tr> ! ! <!-- BEGIN switch_cat_on --> ! <tbody id="phpbbCategory_{catrow.BLOCK_ID}{catrow.CAT_ID}" style="display: ;"> ! <!-- END switch_cat_on --> ! ! <!-- BEGIN switch_cat_off --> ! <tbody id="phpbbCategory_{catrow.BLOCK_ID}{catrow.CAT_ID}" style="display: none;"> ! <!-- END switch_cat_off --> ! ! <!-- BEGIN modulerow --> ! <tr> ! <td class="row1" valign="center" colspan="2">{catrow.modulerow.U_MENU_ICON}<span class="{catrow.modulerow.MENU_STYLE}"><a href="{catrow.modulerow.U_MENU_MODULE}" target="{catrow.modulerow.U_LINK_TARGET}" class="genmed" title="{catrow.modulerow.MENU_DESC}">{catrow.modulerow.MENU_NAME}</a></span></td> ! </tr> ! <!-- END modulerow --> ! ! </tbody> ! </table> ! </td> ! <!-- END catrow --> ! </tr> </table> --- 1,42 ---- ! <table width="{BLOCK_SIZE}" cellpadding="4" cellspacing="0" border="0" class="forumline"> ! <tr> ! <!-- BEGIN catrow --> ! <td class="row1" align="left" width="{CAT_WIDTH}" valign="top"> ! <table width="100%" cellpadding="0" cellspacing="0" border="0"> ! <tr> ! <td class="row2" height="18" width="20" align="center" valign="middle"> ! <!-- BEGIN switch_cat_on --> ! <span class="newsbutton" onClick="rollup_contract(this, 'phpbbCategory_{catrow.BLOCK_ID}{catrow.CAT_ID}', '{catrow.U_CAT_NAV}');"><img src="{catrow.U_CAT_NAV}contract.gif" border="0" /></span> ! <!-- END switch_cat_on --> ! <!-- BEGIN switch_cat_off --> ! <span class="newsbutton" onClick="rollup_contract(this, 'phpbbCategory_{catrow.BLOCK_ID}{catrow.CAT_ID}', '{catrow.U_CAT_NAV}');"><img src="{catrow.U_CAT_NAV}expand.gif" border="0" /></span> ! <!-- END switch_cat_off --> ! </td> ! <td class="row2" align="left" height="18" width="100%"> ! <span class="genmed"><b> {catrow.CATEGORY}</b></span> ! </td> ! </tr> ! <tr> ! <td class="row1" align="left" colspan="2"><span class="genmed">{catrow.DESCRIPTION}</span></td> ! </tr> ! ! <!-- BEGIN switch_cat_on --> ! <tbody id="phpbbCategory_{catrow.BLOCK_ID}{catrow.CAT_ID}" style="display: ;"> ! <!-- END switch_cat_on --> ! ! <!-- BEGIN switch_cat_off --> ! <tbody id="phpbbCategory_{catrow.BLOCK_ID}{catrow.CAT_ID}" style="display: none;"> ! <!-- END switch_cat_off --> ! ! <!-- BEGIN modulerow --> ! <tr> ! <td class="row1" valign="center" colspan="2">{catrow.modulerow.U_MENU_ICON}<span class="{catrow.modulerow.MENU_STYLE}"><a href="{catrow.modulerow.U_MENU_MODULE}" target="{catrow.modulerow.U_LINK_TARGET}" class="genmed" title="{catrow.modulerow.MENU_DESC}">{catrow.modulerow.MENU_NAME}</a></span></td> ! </tr> ! <!-- END modulerow --> ! ! </tbody> ! </table> ! </td> ! <!-- END catrow --> ! </tr> </table> |
|
From: Markus P. <mar...@us...> - 2005-04-19 18:09:10
|
Update of /cvsroot/mxbb/core/modules/mx_coreblocks/templates/subSilver In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv6968/modules/mx_coreblocks/templates/subSilver Removed Files: mx_main_layout.tpl Log Message: Moving mx_main_layout.tpl back to the mx/templates/subSilver folder. --- mx_main_layout.tpl DELETED --- |
|
From: Markus P. <mar...@us...> - 2005-04-19 18:09:10
|
Update of /cvsroot/mxbb/core/templates/subSilver In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv6968/templates/subSilver Added Files: mx_main_layout.tpl Log Message: Moving mx_main_layout.tpl back to the mx/templates/subSilver folder. --- NEW FILE: mx_main_layout.tpl --- <table border="0" cellspacing="10" cellpadding="0" width="100%" class="mx_body_table"> <tr valign="top"> <!-- BEGIN layout_column --> <td class="{layout_column.COL_CLASS}" width="{layout_column.BLOCK_SIZE}"> <!-- BEGIN blocks --> <table width="100%" cellpadding="0" cellspacing="0" border="0" class="mx_graphborder"> <tr> <td> <!-- BEGIN graph_border --> <table width="100%" cellpadding="0" cellspacing="0" border="0"> <tr> <td><img src="{layout_column.blocks.graph_border.TEMPLATE_ROOT_PATH}images/{layout_column.blocks.graph_border.PREFIX}1-1.gif" width="5" height="5" alt="" /></td> <td background="{layout_column.blocks.graph_border.TEMPLATE_ROOT_PATH}images/{layout_column.blocks.graph_border.PREFIX}1-2.gif" width="100%"><img src="{layout_column.blocks.graph_border.TEMPLATE_ROOT_PATH}images/spacer.gif" width="5" height="5" alt="" /></td> <td><img src="{layout_column.blocks.graph_border.TEMPLATE_ROOT_PATH}images/{layout_column.blocks.graph_border.PREFIX}1-3.gif" width="5" height="5" alt="" /></td> </tr> <tr> <td background="{layout_column.blocks.graph_border.TEMPLATE_ROOT_PATH}images/{layout_column.blocks.graph_border.PREFIX}2-1.gif" width="5"><img src="{layout_column.blocks.graph_border.TEMPLATE_ROOT_PATH}images/spacer.gif" width="5" height="5" alt="" /></td> <td background="{layout_column.blocks.graph_border.TEMPLATE_ROOT_PATH}images/{layout_column.blocks.graph_border.PREFIX}2-2.gif" width="100%" align="center"> <!-- END graph_border --> <!-- BEGIN block_header --> <table width="100%" cellpadding="0" cellspacing="0" border="0" class="mx_blockline"> <tr> <!-- END block_header --> <!-- BEGIN show_title --> <th class="{layout_column.blocks.show_title.TITLECLASS}" align="left" width="100%"> {layout_column.blocks.show_title.L_TITLE} </th> <!-- END show_title --> <!-- BEGIN edit --> <th class="{layout_column.blocks.edit.TITLECLASS}" align="right" > <form action="{layout_column.blocks.edit.EDIT_ACTION}" method="post" class="mx_editform"> <table width="100%" cellpadding="0" cellspacing="0" border="0"> <!-- BEGIN switch_edit_on --> <tbody id="phpbbEdit_Blocks" name="phpbbEdit_Blocks" style="display: ;"> <!-- END switch_edit_on --> <!-- BEGIN switch_edit_off --> <tbody id="phpbbEdit_Blocks" name="phpbbEdit_Blocks" style="display: none;"> <!-- END switch_edit_off --> <tr> <!-- BEGIN hidden_block --> <td align="right"><span class="gensmall"><i> {layout_column.blocks.edit.hidden_block.HIDDEN_BLOCK}</i></span></td> <!-- END hidden_block --> <td align="right"> {layout_column.blocks.edit.EDIT_IMG} {layout_column.blocks.edit.S_HIDDEN_FORM_FIELDS} </td> </tr> </tbody> </table> </form> </th> <!-- END edit --> <!-- BEGIN block_header --> </tr> </table> <!-- END block_header --> {layout_column.blocks.BLOCK} <!-- BEGIN graph_border --> </td> <td background="{layout_column.blocks.graph_border.TEMPLATE_ROOT_PATH}images/{layout_column.blocks.graph_border.PREFIX}2-3.gif" width="5"><img src="{layout_column.blocks.graph_border.TEMPLATE_ROOT_PATH}images/spacer.gif" width="5" height="5" alt="" /></td> </tr> <tr> <td><img src="{layout_column.blocks.graph_border.TEMPLATE_ROOT_PATH}images/{layout_column.blocks.graph_border.PREFIX}3-1.gif" width="5" height="5" alt="" /></td> <td background="{layout_column.blocks.graph_border.TEMPLATE_ROOT_PATH}images/{layout_column.blocks.graph_border.PREFIX}3-2.gif" width="100%"><img src="{layout_column.blocks.graph_border.TEMPLATE_ROOT_PATH}images/spacer.gif" width="5" height="5" alt="" /></td> <td><img src="{layout_column.blocks.graph_border.TEMPLATE_ROOT_PATH}images/{layout_column.blocks.graph_border.PREFIX}3-3.gif" width="5" height="5" alt="" /></td> </tr> </table> <!-- END graph_border --> </td> </tr> </table> <!-- BEGIN block_stats --> <div align="right"><span class="copyright">{layout_column.blocks.block_stats.L_BLOCK_UPDATED}{layout_column.blocks.block_stats.EDITOR_NAME} ({layout_column.blocks.block_stats.EDIT_TIME})</span></div> <br clear="all" /> <!-- END block_stats --> <!-- BEGIN no_stats --> <br clear="all" /> <!-- END no_stats --> <!-- END blocks --> </td> <!-- END layout_column --> </tr> </table> |
|
From: Markus P. <mar...@us...> - 2005-04-19 18:02:37
|
Update of /cvsroot/mxbb/core/modules/mx_coreblocks/templates/subSilver In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv3613/templates/subSilver Modified Files: mx_theme.tpl Log Message: Fixed some named array with non-quoted indexes and code layout. Added use of new mx_request_vars class. Index: mx_theme.tpl =================================================================== RCS file: /cvsroot/mxbb/core/modules/mx_coreblocks/templates/subSilver/mx_theme.tpl,v retrieving revision 1.5 retrieving revision 1.6 diff -C2 -d -r1.5 -r1.6 *** mx_theme.tpl 6 Mar 2005 01:10:16 -0000 1.5 --- mx_theme.tpl 19 Apr 2005 18:02:27 -0000 1.6 *************** *** 1,29 **** <table width="{BLOCK_SIZE}" cellpadding="4" cellspacing="0" border="0" class="forumline"> ! <!-- BEGIN switch_is_admin --> ! <tr> <td class="row1" align="center" valign="middle" height="28"><span class="gensmall"> {switch_is_admin.L_CHANGE_NOW} </span></td> ! </tr> ! <tr> ! <td class="row1" align="center" valign="middle" height="28"><span class="gensmall"> ! ! <form method="post" action="{ACTION_URL}"> ! {switch_is_admin.STYLE_SELECT} <br /> ! <input type="submit" class="mainoption" name="change_default_theme" value="{L_CHANGE_NOW}" /> ! </form> ! </span></td> ! </tr> ! <!-- END switch_is_admin --> ! <!-- BEGIN switch_is_user --> ! <tr> <td class="row1" align="center" valign="middle" height="28"><span class="gensmall"> {switch_is_user.L_CHANGE_NOW} </span></td> ! </tr> ! <tr> ! <td class="row1" align="center" valign="middle" height="28"><span class="gensmall"> ! <form method="post" action="{ACTION_URL}"> ! {switch_is_user.STYLE_SELECT} <br /> ! <input type="submit" class="mainoption" name="change_user_theme" value="{L_CHANGE_NOW}" /> ! </form> ! </span></td> ! </tr> ! <!-- END switch_is_user --> ! </table> --- 1,31 ---- <table width="{BLOCK_SIZE}" cellpadding="4" cellspacing="0" border="0" class="forumline"> ! <tr> ! <td class="row1" align="center" valign="middle" height="28"><span class="genmed"> <b>{L_SUBTITLE}</b> </span></td> ! </tr> ! <!-- BEGIN switch_is_admin --> ! <tr> <td class="row1" align="center" valign="middle" height="28"><span class="gensmall"> {switch_is_admin.L_CHANGE_NOW} </span></td> ! </tr> ! <tr> ! <td class="row1" align="center" valign="middle" height="28"> ! <form method="post" action="{ACTION_URL}"> ! {switch_is_admin.STYLE_SELECT} <br /> ! <input type="submit" class="mainoption" name="change_default_theme" value="{L_CHANGE_NOW}" /> ! </form> ! </td> ! </tr> ! <!-- END switch_is_admin --> ! <!-- BEGIN switch_is_user --> ! <tr> <td class="row1" align="center" valign="middle" height="28"><span class="gensmall"> {switch_is_user.L_CHANGE_NOW} </span></td> ! </tr> ! <tr> ! <td class="row1" align="center" valign="middle" height="28"> ! <form method="post" action="{ACTION_URL}"> ! {switch_is_user.STYLE_SELECT} <br /> ! <input type="submit" class="mainoption" name="change_user_theme" value="{L_CHANGE_NOW}" /> ! </form> ! </td> ! </tr> ! <!-- END switch_is_user --> ! </table> |
|
From: Markus P. <mar...@us...> - 2005-04-19 18:02:37
|
Update of /cvsroot/mxbb/core/modules/mx_coreblocks In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv3613 Modified Files: mx_language.php mx_theme.php Log Message: Fixed some named array with non-quoted indexes and code layout. Added use of new mx_request_vars class. Index: mx_language.php =================================================================== RCS file: /cvsroot/mxbb/core/modules/mx_coreblocks/mx_language.php,v retrieving revision 1.8 retrieving revision 1.9 diff -C2 -d -r1.8 -r1.9 *** mx_language.php 19 Apr 2005 17:14:19 -0000 1.8 --- mx_language.php 19 Apr 2005 18:02:26 -0000 1.9 *************** *** 51,55 **** if ( !$db->sql_query($sql) ) { ! mx_message_die(GENERAL_ERROR, "Failed to update user lang configuration", "", __LINE__, __FILE__, $sql); } } --- 51,55 ---- if ( !$db->sql_query($sql) ) { ! mx_message_die(GENERAL_ERROR, "Failed to update user lang configuration", '', __LINE__, __FILE__, $sql); } } *************** *** 75,79 **** $template->assign_vars(array( ! 'ACTION_URL' => $mx_root_path . "index.$phpEx?page=" . $page_id, 'BLOCK_SIZE' => ( !empty($block_size) ? $block_size : '100%' ), 'L_SELECT_LANG' => $lang['Board_lang'], --- 75,79 ---- $template->assign_vars(array( ! 'ACTION_URL' => append_sid(PORTAL_URL . "index.$phpEx?page=$page_id"), 'BLOCK_SIZE' => ( !empty($block_size) ? $block_size : '100%' ), 'L_SELECT_LANG' => $lang['Board_lang'], Index: mx_theme.php =================================================================== RCS file: /cvsroot/mxbb/core/modules/mx_coreblocks/mx_theme.php,v retrieving revision 1.8 retrieving revision 1.9 diff -C2 -d -r1.8 -r1.9 *** mx_theme.php 11 Feb 2005 22:05:55 -0000 1.8 --- mx_theme.php 19 Apr 2005 18:02:27 -0000 1.9 *************** *** 9,16 **** * description : * ------------------------------------------------------------------------- * $Id$ */ ! /** * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by --- 9,17 ---- * description : * ------------------------------------------------------------------------- + * * $Id$ */ ! /** * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by *************** *** 18,88 **** * (at your option) any later version. */ ! if ( !defined( 'IN_PORTAL' ) ) { ! die( "Hacking attempt" ); } ! if ( isset( $HTTP_POST_VARS['change_default_theme'] ) && $userdata['user_level'] == ADMIN ) { ! $board_config['default_style'] = ( isset( $HTTP_POST_VARS['default_style'] ) ) ? $HTTP_POST_VARS['default_style'] : $board_config['default_style']; $sql = "UPDATE " . CONFIG_TABLE . " SET ! config_value = '" . str_replace( "\'", "''", $board_config['default_style'] ) . "' ! WHERE config_name = 'default_style'"; ! if ( !$db->sql_query( $sql ) ) { ! mx_message_die( GENERAL_ERROR, "Failed to update default style configuration for $config_name", "", __LINE__, __FILE__, $sql ); } } ! if ( isset( $HTTP_POST_VARS['change_user_theme'] ) && $userdata['session_logged_in'] ) { ! $userdata['user_style'] = ( isset( $HTTP_POST_VARS['user_style'] ) ) ? $HTTP_POST_VARS['user_style'] : $board_config['default_style']; ! $mx_user_id = $userdata['user_id']; $sql = "UPDATE " . USERS_TABLE . " SET ! user_style = '" . str_replace( "\'", "''", $userdata['user_style'] ) . "' ! WHERE user_id = '$mx_user_id'"; if ( !$db->sql_query( $sql ) ) { ! mx_message_die( GENERAL_ERROR, "Failed to update user style configuration for $config_name", "", __LINE__, __FILE__, $sql ); } } ! $template->set_filenames( array( ! "body_theme" => 'mx_theme.tpl' ) ! ); if ( $userdata['user_level'] == ADMIN ) { ! $template->assign_block_vars( "switch_is_admin", array( 'L_CHANGE_NOW' => $lang['Change_default_style'], ! 'STYLE_SELECT' => style_select( $board_config['default_style'], 'default_style' ) ! ) ); } if ( $userdata['session_logged_in'] ) { ! $template->assign_block_vars( "switch_is_user", array( 'L_CHANGE_NOW' => $lang['Change_user_style'], ! 'STYLE_SELECT' => style_select( $userdata['user_style'], 'user_style' ) ! ) ); ! } ! else ! { ! $block_rows[$block]['show_title'] = 0; ! $block_rows[$block]['show_block'] = 0; } ! $template->assign_vars( array( 'ACTION_URL' => $mx_root_path . "index." . $phpEx . "?page=" . $page_id, ! 'BLOCK_SIZE' => $block_size, ! 'L_BOARD_STYLE' => $board_config['default_style'], ! 'L_CHANGE_NOW' => $lang['Change'], ! 'L_TITLE' => $lang['Theme'], ! 'L_SUBTITLE' => $lang['SelectTheme'] ) ! ); // Display only when the user is logged in ! if ( $userdata['session_logged_in'] ) { ! $template->pparse( "body_theme" ); } --- 19,97 ---- * (at your option) any later version. */ ! ! if ( !defined('IN_PORTAL') ) { ! die("Hacking attempt"); } ! $user_style = $mx_request_vars->post('change_default_theme', MX_TYPE_NO_TAGS, ''); ! $user_style = ( preg_match('#^[a-z_]+$#', $user_style) ? strip_tags($user_style) : '' ); ! if ( !empty($user_style) && $userdata['user_level'] == ADMIN ) { ! $board_config['default_style'] = $user_style; $sql = "UPDATE " . CONFIG_TABLE . " SET ! config_value = '$user_style' ! WHERE config_name = 'default_style'"; ! if ( !$db->sql_query($sql) ) { ! mx_message_die(GENERAL_ERROR, "Failed to update default style configuration", '', __LINE__, __FILE__, $sql); } } ! $user_style = $mx_request_vars->post('change_user_theme', MX_TYPE_NO_TAGS, ''); ! $user_style = ( preg_match('#^[a-z_]+$#', $user_style) ? strip_tags($user_style) : '' ); ! if ( !empty($user_style) && $userdata['session_logged_in'] ) { ! $userdata['user_style'] = $user_style; $sql = "UPDATE " . USERS_TABLE . " SET ! user_style = '$user_style' ! WHERE user_id = '" . $userdata['user_id'] . "'"; if ( !$db->sql_query( $sql ) ) { ! mx_message_die(GENERAL_ERROR, "Failed to update user style configuration", '', __LINE__, __FILE__, $sql); } } ! $template->set_filenames(array( ! 'body_theme' => 'mx_theme.tpl') ! ); if ( $userdata['user_level'] == ADMIN ) { ! $template->assign_block_vars('switch_is_admin', array( ! 'L_CHANGE_NOW' => $lang['Change_default_style'], ! 'STYLE_SELECT' => style_select($board_config['default_style'], 'default_style') ! )); } if ( $userdata['session_logged_in'] ) { ! $template->assign_block_vars('switch_is_user', array( ! 'L_CHANGE_NOW' => $lang['Change_user_style'], ! 'STYLE_SELECT' => style_select($userdata['user_style'], 'user_style') ! )); } ! $template->assign_vars(array( ! 'ACTION_URL' => append_sid(PORTAL_URL . "index.$phpEx?page=$page_id"), ! 'BLOCK_SIZE' => ( !empty($block_size) ? $block_size : '100%' ), ! 'L_BOARD_STYLE' => $board_config['default_style'], ! 'L_CHANGE_NOW' => $lang['Change'], ! 'L_TITLE' => $lang['Theme'], ! 'L_SUBTITLE' => $lang['SelectTheme'] ! )); + // // Display only when the user is logged in ! // if ( $userdata['session_logged_in'] ) { ! $template->pparse('body_theme'); ! } ! else ! { ! $block_rows[$block]['show_title'] = 0; ! $block_rows[$block]['show_block'] = 0; } |
|
From: Markus P. <mar...@us...> - 2005-04-19 17:19:01
|
Update of /cvsroot/mxbb/core/modules/mx_coreblocks/templates/subSilver In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv12751/templates/subSilver Modified Files: mx_login.tpl Log Message: Fixed some named array with non-quoted indexes and code layout. Added use of new mx_request_vars class. Index: mx_login.tpl =================================================================== RCS file: /cvsroot/mxbb/core/modules/mx_coreblocks/templates/subSilver/mx_login.tpl,v retrieving revision 1.5 retrieving revision 1.6 diff -C2 -d -r1.5 -r1.6 *** mx_login.tpl 6 Mar 2005 01:10:16 -0000 1.5 --- mx_login.tpl 19 Apr 2005 17:18:48 -0000 1.6 *************** *** 1,14 **** ! <table width="{BLOCK_SIZE}" cellpadding="4" cellspacing="0" border="0" class="forumline" > ! <tr> ! <td class="row1" valign="middle" height="28"><span class="gensmall"> ! <form action="{S_LOGIN_ACTION}" method="post"> ! {L_USERNAME}:<br /><input class="post" type="text" name="username" size="10" /><br /> ! {L_PASSWORD}:<br /><input class="post" type="password" name="password" size="10" /><br /> ! <input class="text" type="checkbox" name="autologin" value="ON" /> {L_AUTO_LOGIN}<br /> ! <input type="submit" class="mainoption" name="login" value="{L_LOGIN}" /> ! </form> ! </td> ! </tr> </table> - - \ No newline at end of file --- 1,12 ---- ! <table width="{BLOCK_SIZE}" cellpadding="4" cellspacing="0" border="0" class="forumline"> ! <tr> ! <td class="row1" valign="middle" height="28"><span class="gensmall"> ! <form action="{S_LOGIN_ACTION}" method="post"> ! {L_USERNAME}:<br /><input class="post" type="text" name="username" size="10" /><br /> ! {L_PASSWORD}:<br /><input class="post" type="password" name="password" size="10" /><br /> ! <input type="checkbox" class="post" name="autologin" value="ON" /> {L_AUTO_LOGIN}<br /> ! <input type="submit" class="mainoption" name="login" value="{L_LOGIN}" /> ! </form> ! </td> ! </tr> </table> |
|
From: Markus P. <mar...@us...> - 2005-04-19 17:19:01
|
Update of /cvsroot/mxbb/core/modules/mx_coreblocks In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv12751 Modified Files: mx_login.php Log Message: Fixed some named array with non-quoted indexes and code layout. Added use of new mx_request_vars class. Index: mx_login.php =================================================================== RCS file: /cvsroot/mxbb/core/modules/mx_coreblocks/mx_login.php,v retrieving revision 1.5 retrieving revision 1.6 diff -C2 -d -r1.5 -r1.6 *** mx_login.php 9 Jan 2005 21:55:44 -0000 1.5 --- mx_login.php 19 Apr 2005 17:18:47 -0000 1.6 *************** *** 19,47 **** * (at your option) any later version. */ ! ! if ( !defined( 'IN_PORTAL' ) ) { ! die( "Hacking attempt" ); } ! $template->set_filenames( array( "body_login" => 'mx_login.tpl' ) ! ); - $template->assign_vars( array( 'BLOCK_SIZE' => $block_size, - 'S_LOGIN_ACTION' => append_sid( 'login.' . $phpEx ), - 'L_USERNAME' => $lang['Username'], - 'L_PASSWORD' => $lang['Password'], - 'L_LOGIN' => $lang['Login'], - 'L_TITLE' => $lang['Login'], - 'L_LOG_ME_IN' => $lang['Log_me_in'], - 'L_AUTO_LOGIN' => $lang['Log_me_in'], - 'L_LOGIN_LOGOUT' => $lang['Login'] ) - ); // if( !$userdata['session_logged_in'] ) // { ! $template->assign_block_vars( 'switch_user_logged_out', array() ); ! $template->pparse( "body_login" ); // } - $template->destroy(); ?> \ No newline at end of file --- 19,49 ---- * (at your option) any later version. */ ! ! if ( !defined('IN_PORTAL') ) { ! die("Hacking attempt"); } ! $template->set_filenames(array( ! 'body_login' => 'mx_login.tpl') ! ); ! ! $template->assign_vars(array( ! 'BLOCK_SIZE' => $block_size, ! 'S_LOGIN_ACTION' => append_sid(PORTAL_URL . "login.$phpEx"), ! 'L_USERNAME' => $lang['Username'], ! 'L_PASSWORD' => $lang['Password'], ! 'L_LOGIN' => $lang['Login'], ! 'L_TITLE' => $lang['Login'], ! 'L_LOG_ME_IN' => $lang['Log_me_in'], ! 'L_AUTO_LOGIN' => $lang['Log_me_in'], ! 'L_LOGIN_LOGOUT' => $lang['Login'] ! )); // if( !$userdata['session_logged_in'] ) // { ! $template->assign_block_vars('switch_user_logged_out', array()); ! $template->pparse('body_login'); // } ?> \ No newline at end of file |
|
From: Markus P. <mar...@us...> - 2005-04-19 17:14:30
|
Update of /cvsroot/mxbb/core/modules/mx_coreblocks/templates/subSilver In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv10345/templates/subSilver Modified Files: mx_google.tpl mx_includex.tpl mx_language.tpl Log Message: Fixed some named array with non-quoted indexes and code layout. Added use of new mx_request_vars class. Index: mx_language.tpl =================================================================== RCS file: /cvsroot/mxbb/core/modules/mx_coreblocks/templates/subSilver/mx_language.tpl,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** mx_language.tpl 6 Mar 2005 01:10:16 -0000 1.4 --- mx_language.tpl 19 Apr 2005 17:14:19 -0000 1.5 *************** *** 1,33 **** <table width="{BLOCK_SIZE}" cellpadding="4" cellspacing="0" border="0" class="forumline"> ! <tr> <td class="row1" align="center" valign="middle" height="28"><span class="genmed"> <b>{L_SUBTITLE}</b> </span></td> ! </tr> ! <!-- BEGIN switch_is_admin --> ! <tr> <td class="row1" align="center" valign="middle" height="28"><span class="gensmall"> {switch_is_admin.L_CHANGE_NOW} </span></td> ! </tr> ! <tr> ! <td class="row1" align="center" valign="middle" height="28"> ! <span class="gensmall"> ! <form method="post" action="{ACTION_URL}"> ! {switch_is_admin.LANG_SELECT} <br /> ! <input type="submit" class="mainoption" name="change_default_lang" value="{L_CHANGE_NOW}" /> ! </form> ! </span></td> ! </tr> ! <!-- END switch_is_admin --> ! <!-- BEGIN switch_is_user --> ! <tr> <td class="row1" align="center" valign="middle" height="28"><span class="gensmall"> {switch_is_user.L_CHANGE_NOW} </span></td> ! </tr> ! <tr> ! <td class="row1" align="center" valign="middle" height="28"> ! <span class="gensmall"> ! <form method="post" action="{ACTION_URL}"> ! {switch_is_user.LANG_SELECT} <br /> ! <input type="submit" class="mainoption" name="change_user_lang" value="{L_CHANGE_NOW}" /> ! </form> ! </span></td> ! </tr> ! <!-- END switch_is_user --> ! </table> --- 1,31 ---- <table width="{BLOCK_SIZE}" cellpadding="4" cellspacing="0" border="0" class="forumline"> ! <tr> <td class="row1" align="center" valign="middle" height="28"><span class="genmed"> <b>{L_SUBTITLE}</b> </span></td> ! </tr> ! <!-- BEGIN switch_is_admin --> ! <tr> <td class="row1" align="center" valign="middle" height="28"><span class="gensmall"> {switch_is_admin.L_CHANGE_NOW} </span></td> ! </tr> ! <tr> ! <td class="row1" align="center" valign="middle" height="28"> ! <form method="post" action="{ACTION_URL}"> ! {switch_is_admin.LANG_SELECT} <br /> ! <input type="submit" class="mainoption" name="change_default_lang" value="{L_CHANGE_NOW}" /> ! </form> ! </td> ! </tr> ! <!-- END switch_is_admin --> ! <!-- BEGIN switch_is_user --> ! <tr> <td class="row1" align="center" valign="middle" height="28"><span class="gensmall"> {switch_is_user.L_CHANGE_NOW} </span></td> ! </tr> ! <tr> ! <td class="row1" align="center" valign="middle" height="28"> ! <form method="post" action="{ACTION_URL}"> ! {switch_is_user.LANG_SELECT} <br /> ! <input type="submit" class="mainoption" name="change_user_lang" value="{L_CHANGE_NOW}" /> ! </form> ! </td> ! </tr> ! <!-- END switch_is_user --> ! </table> Index: mx_includex.tpl =================================================================== RCS file: /cvsroot/mxbb/core/modules/mx_coreblocks/templates/subSilver/mx_includex.tpl,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** mx_includex.tpl 6 Mar 2005 01:10:16 -0000 1.2 --- mx_includex.tpl 19 Apr 2005 17:14:19 -0000 1.3 *************** *** 2,41 **** <!-- BEGIN iframe_mode --> ! <tr> ! <td align="left"> ! <iframe width="100%" height="{iframe_mode.IFRAME_HEIGHT}" src="{iframe_mode.FILE_URL}" FRAMEBORDER=0> ! If you can see this, your browser doesn't understand IFRAME. However, we'll still <A HREF="{iframe_mode.FILE_URL}">link</A> you to the file. ! </iframe> ! </td> ! </tr> <!-- END iframe_mode --> <!-- BEGIN textfile_mode --> ! <tr> ! <td class="row1" align="left" >{textfile_mode.FILE_CONTENTS}</td> ! </tr> <!-- END textfile_mode --> <!-- BEGIN multimedia_mode --> ! <tr> ! <td class="row1_no_trans" align="left" > ! <div align="center"> ! <object width="320" height="315" ! classid="clsid:22D6F312-B0F6-11D0-94AB-0080C74C7E95"> ! <param name="src" value="{multimedia_mode.MEDIA_URL}"> ! <embed src="/directory/sample.wmv" {multimedia_mode.WIDTH} {multimedia_mode.HEIGHT} ! pluginspage="http://www.microsoft.com/Windows/MediaPlayer/" type="video/x-ms-asf-plugin"> ! </embed> ! </object> ! <!-- <embed type="application/x-mplayer2" src="{multimedia_mode.MEDIA_URL}" {multimedia_mode.HEIGHT} {multimedia_mode.WIDTH} border="0" autoplay="TRUE" controller="TRUE" pluginspage="http://www.microsoft.com/windows/windowsmedia/default.asp" ></embed> --> ! </div> ! </td> ! </tr> <!-- END multimedia_mode --> <!-- BEGIN pic_mode --> ! <tr> ! <td class="row1" align="left" >{FILE_CONTENTS}</td> ! </tr> <!-- END pic_mode --> --- 2,40 ---- <!-- BEGIN iframe_mode --> ! <tr> ! <td align="left"> ! <iframe width="100%" height="{iframe_mode.IFRAME_HEIGHT}" src="{iframe_mode.FILE_URL}" frameborder="0"> ! If you can see this, your browser doesn't understand IFRAME. However, we'll still <a href="{iframe_mode.FILE_URL}">link</a> you to the file. ! </iframe> ! </td> ! </tr> <!-- END iframe_mode --> <!-- BEGIN textfile_mode --> ! <tr> ! <td class="row1" align="left" >{textfile_mode.FILE_CONTENTS}</td> ! </tr> <!-- END textfile_mode --> <!-- BEGIN multimedia_mode --> ! <tr> ! <td class="row1_no_trans" align="left"> ! <div align="center"> ! <object width="320" height="315" classid="clsid:22D6F312-B0F6-11D0-94AB-0080C74C7E95"> ! <param name="src" value="{multimedia_mode.MEDIA_URL}"> ! <embed src="/directory/sample.wmv" {multimedia_mode.WIDTH} {multimedia_mode.HEIGHT} ! pluginspage="http://www.microsoft.com/Windows/MediaPlayer/" type="video/x-ms-asf-plugin"> ! </embed> ! </object> ! <!-- <embed type="application/x-mplayer2" src="{multimedia_mode.MEDIA_URL}" {multimedia_mode.HEIGHT} {multimedia_mode.WIDTH} border="0" autoplay="TRUE" controller="TRUE" pluginspage="http://www.microsoft.com/windows/windowsmedia/default.asp" ></embed> --> ! </div> ! </td> ! </tr> <!-- END multimedia_mode --> <!-- BEGIN pic_mode --> ! <tr> ! <td class="row1" align="left" >{FILE_CONTENTS}</td> ! </tr> <!-- END pic_mode --> Index: mx_google.tpl =================================================================== RCS file: /cvsroot/mxbb/core/modules/mx_coreblocks/templates/subSilver/mx_google.tpl,v retrieving revision 1.5 retrieving revision 1.6 diff -C2 -d -r1.5 -r1.6 *** mx_google.tpl 6 Mar 2005 01:10:16 -0000 1.5 --- mx_google.tpl 19 Apr 2005 17:14:19 -0000 1.6 *************** *** 1,19 **** <table width="{BLOCK_SIZE}" cellpadding="4" cellspacing="0" border="0" class="forumline"> ! <tr> ! <td class="row1" align="center" valign="middle" height="28"> ! <!-- Champ de recherche Google --> ! <center> ! <FORM method=GET action="http://www.google.com/search"> ! ! <A HREF="http://www.google.com" target="_blank"> ! <IMG SRC="http://www.google.com/logos/Logo_40wht.gif" border="0" ! ALT="Google" align="absmiddle"></A> ! <INPUT TYPE=text name=q size=25 maxlength=255 value=""> ! <INPUT TYPE=hidden name=hl value=en> ! <INPUT type=submit class="mainoption" name=btnG VALUE="{L_SEARCH}"> ! </FORM> ! </center> ! <!-- Google --> ! </td> ! </tr> ! </table> \ No newline at end of file --- 1,11 ---- <table width="{BLOCK_SIZE}" cellpadding="4" cellspacing="0" border="0" class="forumline"> ! <tr> ! <td class="row1" align="center" valign="middle" height="28"> ! <a href="http://www.google.com" target="_blank"><img src="http://www.google.com/logos/Logo_40wht.gif" border="0" alt="Google" title="Google" align="absmiddle" /></a> ! <form method="get" action="http://www.google.com/search"> ! <input class="post" type="text" name="q" size="25" maxlength="255" value="" /> ! <input type="submit" class="mainoption" name="btnG" value="{L_SEARCH}" /> ! </form> ! </td> ! </tr> ! </table> \ No newline at end of file |
|
From: Markus P. <mar...@us...> - 2005-04-19 17:14:30
|
Update of /cvsroot/mxbb/core/modules/mx_coreblocks In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv10345 Modified Files: mx_google.php mx_includex.php mx_language.php Log Message: Fixed some named array with non-quoted indexes and code layout. Added use of new mx_request_vars class. Index: mx_language.php =================================================================== RCS file: /cvsroot/mxbb/core/modules/mx_coreblocks/mx_language.php,v retrieving revision 1.7 retrieving revision 1.8 diff -C2 -d -r1.7 -r1.8 *** mx_language.php 6 Mar 2005 01:10:13 -0000 1.7 --- mx_language.php 19 Apr 2005 17:14:19 -0000 1.8 *************** *** 19,85 **** * (at your option) any later version. */ ! ! if ( !defined( 'IN_PORTAL' ) ) { ! die( "Hacking attempt" ); } ! if ( isset( $HTTP_POST_VARS['change_default_lang'] ) && $userdata['user_level'] == ADMIN ) { ! $board_config['default_lang'] = ( isset( $HTTP_POST_VARS['default_lang'] ) ) ? $HTTP_POST_VARS['default_lang'] : $board_config['default_lang']; $sql = "UPDATE " . CONFIG_TABLE . " SET ! config_value = '" . str_replace( "\'", "''", $board_config['default_lang'] ) . "' ! WHERE config_name = 'default_lang'"; ! if ( !$db->sql_query( $sql ) ) { ! mx_message_die( GENERAL_ERROR, "Failed to update default language configuration for $config_name", "", __LINE__, __FILE__, $sql ); } } ! if ( isset( $HTTP_POST_VARS['change_user_lang'] ) && $userdata['session_logged_in'] ) { ! $userdata['user_lang'] = ( isset( $HTTP_POST_VARS['user_lang'] ) ) ? $HTTP_POST_VARS['user_lang'] : $board_config['default_lang']; ! $mx_user_id = $userdata['user_id']; $sql = "UPDATE " . USERS_TABLE . " SET ! user_lang = '" . str_replace( "\'", "''", $userdata['user_lang'] ) . "' ! WHERE user_id = '$mx_user_id'"; ! if ( !$db->sql_query( $sql ) ) { ! mx_message_die( GENERAL_ERROR, "Failed to update user lang configuration for $config_name", "", __LINE__, __FILE__, $sql ); } } ! $template->set_filenames( array( ! "body_language" => 'mx_language.tpl' ) ! ); if ( $userdata['user_level'] == ADMIN ) { ! $template->assign_block_vars( "switch_is_admin", array( 'L_CHANGE_NOW' => $lang['Change_default_lang'], ! 'LANG_SELECT' => language_select( $board_config['default_lang'], 'default_lang' ) ! ) ); } if ( $userdata['session_logged_in'] ) { ! $template->assign_block_vars( "switch_is_user", array( 'L_CHANGE_NOW' => $lang['Change_user_lang'], ! 'LANG_SELECT' => language_select( $userdata['user_lang'], 'user_lang' ) ! ) ); } ! $template->assign_vars( array( 'ACTION_URL' => $mx_root_path . "index." . $phpEx . "?page=" . $page_id, ! 'BLOCK_SIZE' => ( !empty( $block_size ) ? $block_size : '100%' ), ! 'L_SELECT_LANG' => $lang['Board_lang'], ! 'L_CHANGE_NOW' => $lang['Change'], ! 'L_TITLE' => $lang['Portal_lang'], ! 'L_SUBTITLE' => $lang['SELECTGUILANG'] ! ) ); // Display only when the user is logged in ! if ( $userdata['session_logged_in'] ) { ! $template->pparse( "body_language" ); } else --- 19,92 ---- * (at your option) any later version. */ ! ! if ( !defined('IN_PORTAL') ) { ! die("Hacking attempt"); } ! $language = $mx_request_vars->post('change_default_lang', MX_TYPE_NO_TAGS, ''); ! $language = ( preg_match('#^[a-z_]+$#', $language) ? strip_tags($language) : '' ); ! if ( !empty($language) && $userdata['user_level'] == ADMIN ) { ! $board_config['default_lang'] = $language; $sql = "UPDATE " . CONFIG_TABLE . " SET ! config_value = '$language' ! WHERE config_name = 'default_lang'"; ! if ( !$db->sql_query($sql) ) { ! mx_message_die(GENERAL_ERROR, "Failed to update default language configuration", '', __LINE__, __FILE__, $sql); } } ! $language = $mx_request_vars->post('change_user_lang', MX_TYPE_NO_TAGS, ''); ! $language = ( preg_match('#^[a-z_]+$#', $language) ? strip_tags($language) : '' ); ! if ( !empty($language) && $userdata['session_logged_in'] ) { ! $userdata['user_lang'] = $language; $sql = "UPDATE " . USERS_TABLE . " SET ! user_lang = '$language' ! WHERE user_id = '" . $userdata['user_id'] . "'"; ! if ( !$db->sql_query($sql) ) { ! mx_message_die(GENERAL_ERROR, "Failed to update user lang configuration", "", __LINE__, __FILE__, $sql); } } ! $template->set_filenames(array( ! 'body_language' => 'mx_language.tpl') ! ); if ( $userdata['user_level'] == ADMIN ) { ! $template->assign_block_vars('switch_is_admin', array( ! 'L_CHANGE_NOW' => $lang['Change_default_lang'], ! 'LANG_SELECT' => language_select($board_config['default_lang'], 'default_lang') ! )); } if ( $userdata['session_logged_in'] ) { ! $template->assign_block_vars('switch_is_user', array( ! 'L_CHANGE_NOW' => $lang['Change_user_lang'], ! 'LANG_SELECT' => language_select($userdata['user_lang'], 'user_lang') ! )); } ! $template->assign_vars(array( ! 'ACTION_URL' => $mx_root_path . "index.$phpEx?page=" . $page_id, ! 'BLOCK_SIZE' => ( !empty($block_size) ? $block_size : '100%' ), ! 'L_SELECT_LANG' => $lang['Board_lang'], ! 'L_CHANGE_NOW' => $lang['Change'], ! 'L_TITLE' => $lang['Portal_lang'], ! 'L_SUBTITLE' => $lang['SELECTGUILANG'] ! )); + // // Display only when the user is logged in ! // if ( $userdata['session_logged_in'] ) { ! $template->pparse('body_language'); } else Index: mx_includex.php =================================================================== RCS file: /cvsroot/mxbb/core/modules/mx_coreblocks/mx_includex.php,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** mx_includex.php 17 Mar 2005 11:30:36 -0000 1.3 --- mx_includex.php 19 Apr 2005 17:14:19 -0000 1.4 *************** *** 19,113 **** * (at your option) any later version. */ ! ! if ( !defined( 'IN_PORTAL' ) ) { ! die( "Hacking attempt" ); } ! $block_config = read_block_config( $block_id ); $title = $block_config[$block_id]['block_title']; $select_row = array('x_listen', 'x_iframe', 'x_textfile', 'x_multimedia', 'x_pic', 'x_format'); ! $iframe_mode = $select_row[$block_config[$block_id]['x_mode']['parameter_value']] ; ! $x_mode = $iframe_mode == 'x_listen' && !empty( $HTTP_GET_VARS['x_mode'] ) ? $HTTP_GET_VARS['x_mode'] : $iframe_mode ; ! $x_1 = $iframe_mode == 'x_listen' && !empty( $HTTP_GET_VARS['x_1'] ) ? $HTTP_GET_VARS['x_1'] : $block_config[$block_id]['x_1']['parameter_value'] ; ! $x_2 = $iframe_mode == 'x_listen' && !empty( $HTTP_GET_VARS['x_2'] ) ? $HTTP_GET_VARS['x_2'] : $block_config[$block_id]['x_2']['parameter_value'] ; ! $x_3 = $iframe_mode == 'x_listen' && !empty( $HTTP_GET_VARS['x_3'] ) ? $HTTP_GET_VARS['x_3'] : $block_config[$block_id]['x_3']['parameter_value'] ; // Start output of page ! $template->set_filenames( array( ! "includex_block" => "mx_includex.tpl" ) ! ); ! $template->assign_vars( array( ! 'BLOCK_SIZE' => ( !empty( $block_size ) ? $block_size : '100%' ), ! 'L_TITLE' => ( !empty( $lang[$title] ) ? $lang[$title] : $title ) ! ) ); ! switch ( $x_mode ) { ! case 'x_listen': // Listen ! break; ! ! case 'x_iframe': // Iframe $file_url = $x_1; ! ! if ( substr_count( $file_url, "http://" ) == 0 ) { $file_url = PORTAL_URL . $file_url; } ! ! $template->assign_block_vars( 'iframe_mode', array( 'FILE_URL' => $file_url, ! 'IFRAME_HEIGHT' => $x_2 ! ) ); ! break; ! ! case 'x_textfile': // Textfile ob_start(); ! @readfile( $mx_root_path . $file ); $file_contents = ob_get_contents(); ob_clean(); ! ! $template->assign_block_vars( 'textfile_mode', array( 'FILE_CONTENTS' => $file_contents ! ) ); ! break; ! ! case 'x_multimedia': // Multimedia ! ! ! $template->assign_block_vars( 'multimedia_mode', array( 'MEDIA_URL' => PORTAL_URL . $x_1, 'WIDTH' => !empty($x_2) ? 'width="'.$x_2.'"' : '', 'HEIGHT' => !empty($x_3) ? 'height="'.$x_3.'"' : '' ! ! ) ); ! break; ! ! case 'x_pic': // Pic ! ! $template->assign_block_vars( 'pic_mode', array( 'FILE_CONTENTS' => $file_contents ! ) ); ! break; ! ! case 'x_format': // Formatted file ! // not ready ;) do nothing ! break; ! ! default: ! // Hidden $block_rows[$block]['show_title'] = 0; $block_rows[$block]['show_block'] = 0; return; - break; } ! $template->pparse( "includex_block" ); ?> \ No newline at end of file --- 19,107 ---- * (at your option) any later version. */ ! ! if ( !defined('IN_PORTAL') ) { ! die("Hacking attempt"); } ! $block_config = read_block_config($block_id); $title = $block_config[$block_id]['block_title']; $select_row = array('x_listen', 'x_iframe', 'x_textfile', 'x_multimedia', 'x_pic', 'x_format'); ! $iframe_mode = $select_row[$block_config[$block_id]['x_mode']['parameter_value']]; ! $x_mode = ( $iframe_mode == 'x_listen' && !empty($HTTP_GET_VARS['x_mode']) ? $HTTP_GET_VARS['x_mode'] : $iframe_mode ); ! $x_1 = ( $iframe_mode == 'x_listen' && !empty($HTTP_GET_VARS['x_1']) ? $HTTP_GET_VARS['x_1'] : $block_config[$block_id]['x_1']['parameter_value'] ); ! $x_2 = ( $iframe_mode == 'x_listen' && !empty($HTTP_GET_VARS['x_2']) ? $HTTP_GET_VARS['x_2'] : $block_config[$block_id]['x_2']['parameter_value'] ); ! $x_3 = ( $iframe_mode == 'x_listen' && !empty($HTTP_GET_VARS['x_3']) ? $HTTP_GET_VARS['x_3'] : $block_config[$block_id]['x_3']['parameter_value'] ); // Start output of page ! $template->set_filenames(array( ! 'includex_block' => 'mx_includex.tpl') ! ); ! $template->assign_vars(array( ! 'BLOCK_SIZE' => ( !empty($block_size) ? $block_size : '100%' ), ! 'L_TITLE' => ( !empty($lang[$title]) ? $lang[$title] : $title ) ! )); ! switch( $x_mode ) { ! case 'x_listen': // Listen ! break; ! ! case 'x_iframe': // Iframe $file_url = $x_1; ! ! if ( substr_count($file_url, 'http://') == 0 ) { $file_url = PORTAL_URL . $file_url; } ! ! $template->assign_block_vars('iframe_mode', array( 'FILE_URL' => $file_url, ! 'IFRAME_HEIGHT' => $x_2 ! )); ! break; ! ! case 'x_textfile': // Textfile ob_start(); ! @readfile($mx_root_path . $file); $file_contents = ob_get_contents(); ob_clean(); ! ! $template->assign_block_vars('textfile_mode', array( 'FILE_CONTENTS' => $file_contents ! )); ! break; ! ! case 'x_multimedia': // Multimedia ! $template->assign_block_vars('multimedia_mode', array( 'MEDIA_URL' => PORTAL_URL . $x_1, 'WIDTH' => !empty($x_2) ? 'width="'.$x_2.'"' : '', 'HEIGHT' => !empty($x_3) ? 'height="'.$x_3.'"' : '' ! )); ! break; ! ! case 'x_pic': // Pic ! $template->assign_block_vars('pic_mode', array( 'FILE_CONTENTS' => $file_contents ! )); ! break; ! ! case 'x_format': // Formatted file ! // not ready ;) do nothing ! break; ! ! default: // Hidden $block_rows[$block]['show_title'] = 0; $block_rows[$block]['show_block'] = 0; return; } ! $template->pparse('includex_block'); ?> \ No newline at end of file Index: mx_google.php =================================================================== RCS file: /cvsroot/mxbb/core/modules/mx_coreblocks/mx_google.php,v retrieving revision 1.5 retrieving revision 1.6 diff -C2 -d -r1.5 -r1.6 *** mx_google.php 9 Jan 2005 21:55:44 -0000 1.5 --- mx_google.php 19 Apr 2005 17:14:18 -0000 1.6 *************** *** 20,37 **** */ ! if ( !defined( 'IN_PORTAL' ) ) { ! die( "Hacking attempt" ); } ! $template->set_filenames( array( 'body_google' => 'mx_google.tpl' ! ) ); ! $template->assign_vars( array( 'BLOCK_SIZE' => $block_size, ! 'L_SEARCH' => $lang['Search'], ! 'L_TITLE' => 'Google' ! ) ); ! $template->pparse( "body_google" ); ?> \ No newline at end of file --- 20,39 ---- */ ! if ( !defined('IN_PORTAL') ) { ! die("Hacking attempt"); } ! $template->set_filenames(array( ! 'body_google' => 'mx_google.tpl') ! ); ! $template->assign_vars(array( ! 'BLOCK_SIZE' => $block_size, ! 'L_SEARCH' => $lang['Search'], ! 'L_TITLE' => 'Google' ! )); ! $template->pparse('body_google'); ?> \ No newline at end of file |
|
From: Markus P. <mar...@us...> - 2005-04-19 16:03:32
|
Update of /cvsroot/mxbb/core/modules/mx_coreblocks In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv5683 Modified Files: mx_dynamic.php Log Message: Fixed some named array with non-quoted indexes and code layout. Added use of new mx_request_vars class. Index: mx_dynamic.php =================================================================== RCS file: /cvsroot/mxbb/core/modules/mx_coreblocks/mx_dynamic.php,v retrieving revision 1.7 retrieving revision 1.8 diff -C2 -d -r1.7 -r1.8 *** mx_dynamic.php 17 Mar 2005 11:30:36 -0000 1.7 --- mx_dynamic.php 19 Apr 2005 16:03:24 -0000 1.8 *************** *** 22,41 **** if ( !defined( 'IN_PORTAL' ) ) { ! die( "Hacking attempt" ); } // Mode setting ! $dynamic_block_config = read_block_config( $block_id ); ! if ( isset( $HTTP_POST_VARS['dynamic_block'] ) || isset( $HTTP_GET_VARS['dynamic_block'] ) ) ! { ! $dynamic_block_id = ( isset( $HTTP_POST_VARS['dynamic_block'] ) ) ? intval( $HTTP_POST_VARS['dynamic_block'] ) : intval( $HTTP_GET_VARS['dynamic_block'] ); ! } ! else ! { ! $dynamic_block_id = intval( $dynamic_block_config[$block_id]['default_block_id']['parameter_value'] ); ! } ! if ( $dynamic_block_id == '0' ) { return; --- 22,36 ---- if ( !defined( 'IN_PORTAL' ) ) { ! die("Hacking attempt"); } + // // Mode setting ! // ! $dynamic_block_config = read_block_config($block_id); ! $dynamic_block_id = $mx_request_vars->request('dynamic_block', MX_TYPE_INT, $dynamic_block_config[$block_id]['default_block_id']['parameter_value']); ! if ( $dynamic_block_id == 0 ) { return; *************** *** 45,80 **** $sql = "SELECT * ! FROM " . COLUMN_BLOCK_TABLE . " bct, ! " . BLOCK_TABLE . " blk, ! " . FUNCTION_TABLE . " fnc, ! " . MODULE_TABLE . " mdl ! WHERE blk.function_id = fnc.function_id ! AND blk.block_id = " . $dynamic_block_id . " ! AND fnc.module_id = mdl.module_id ! ORDER BY column_id, block_order"; ! if ( !$q_modules = $db->sql_query( $sql ) ) { ! mx_message_die( GENERAL_ERROR, "Could not query modules information", "", __LINE__, __FILE__, $sql ); } ! if ( $total_block = $db->sql_numrows( $q_modules ) ) { ! $block_rows_dynamic = $db->sql_fetchrow( $q_modules ); } ! $block_config_dynamic = read_block_config( $dynamic_block_id ); ! $is_auth_ary = array(); ! $is_auth_ary = block_auth( AUTH_VIEW, $dynamic_block_id, $userdata, $block_config_dynamic[$dynamic_block_id]['auth_view'], $block_config_dynamic[$dynamic_block_id]['auth_view_group'] ); $module_root_path = $block_rows_dynamic['module_path']; ! $dynamic_admin_file = !empty( $block_rows_dynamic['function_admin'] ) ? $block_rows_dynamic['function_admin'] : 'admin/admin_mx_block.php'; $block_file = $block_rows_dynamic['function_file']; // Overwrite with block info ! $dynamic_main_block_id = $mx_block_id; // Main block id $mx_block_id = $dynamic_block_id; // Dynamic block id --- 40,75 ---- $sql = "SELECT * ! FROM " . COLUMN_BLOCK_TABLE . " bct, ! " . BLOCK_TABLE . " blk, ! " . FUNCTION_TABLE . " fnc, ! " . MODULE_TABLE . " mdl ! WHERE blk.function_id = fnc.function_id ! AND blk.block_id = " . $dynamic_block_id . " ! AND fnc.module_id = mdl.module_id ! ORDER BY column_id, block_order"; ! if ( !($q_modules = $db->sql_query($sql)) ) { ! mx_message_die(GENERAL_ERROR, "Could not query modules information", "", __LINE__, __FILE__, $sql); } ! if ( $total_block = $db->sql_numrows($q_modules) ) { ! $block_rows_dynamic = $db->sql_fetchrow($q_modules); } ! $block_config_dynamic = read_block_config($dynamic_block_id); ! $is_auth_ary = block_auth(AUTH_VIEW, $dynamic_block_id, $userdata, $block_config_dynamic[$dynamic_block_id]['auth_view'], $block_config_dynamic[$dynamic_block_id]['auth_view_group']); $module_root_path = $block_rows_dynamic['module_path']; ! $dynamic_admin_file = !empty($block_rows_dynamic['function_admin']) ? $block_rows_dynamic['function_admin'] : 'admin/admin_mx_block.php'; $block_file = $block_rows_dynamic['function_file']; + // // Overwrite with block info ! // $dynamic_main_block_id = $mx_block_id; // Main block id $mx_block_id = $dynamic_block_id; // Dynamic block id *************** *** 83,89 **** $mx_block_config = $block_config = $block_config_dynamic; ! if ( $is_auth_ary[auth_view] && $block_rows_dynamic['show_block'] == 1 || $is_auth_ary[auth_mod] ) { ! include( $module_root_path . $block_file ); } --- 78,84 ---- $mx_block_config = $block_config = $block_config_dynamic; ! if ( $is_auth_ary['auth_view'] && $block_rows_dynamic['show_block'] == 1 || $is_auth_ary['auth_mod'] ) { ! include($module_root_path . $block_file); } |
|
From: Markus P. <mar...@us...> - 2005-04-19 15:55:50
|
Update of /cvsroot/mxbb/core/modules/mx_coreblocks In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv2884 Modified Files: mx_announce.php Log Message: Fixed some named array with non-quoted indexes and code layout. Fixed last post date in announcement block. Index: mx_announce.php =================================================================== RCS file: /cvsroot/mxbb/core/modules/mx_coreblocks/mx_announce.php,v retrieving revision 1.12 retrieving revision 1.13 diff -C2 -d -r1.12 -r1.13 *** mx_announce.php 6 Mar 2005 01:10:13 -0000 1.12 --- mx_announce.php 19 Apr 2005 15:55:39 -0000 1.13 *************** *** 19,52 **** * (at your option) any later version. */ - - // Read block Configuration ! $block_config = read_block_config( $block_id ); $title = $block_config[$block_id]['block_title']; ! $announce_nbr_display = $block_config[$block_id][announce_nbr_display]['parameter_value']; ! $announce_nbr_days = $block_config[$block_id][announce_nbr_days]['parameter_value']; ! $announce_display_global = $block_config[$block_id][announce_display_global]['parameter_value']; ! $announce_display = $block_config[$block_id][announce_display]['parameter_value']; ! $announce_display_sticky = $block_config[$block_id][announce_display_sticky]['parameter_value']; ! $announce_display_normal = $block_config[$block_id][announce_display_normal]['parameter_value']; ! $announce_img_global = $block_config[$block_id][announce_img_global]['parameter_value']; ! $announce_img = $block_config[$block_id][announce_img]['parameter_value']; ! $announce_img_sticky = $block_config[$block_id][announce_img_sticky]['parameter_value']; ! $announce_img_normal = $block_config[$block_id][announce_img_normal]['parameter_value']; ! $announce_forum = $block_config[$block_id][announce_forum]['parameter_value']; ! if ( empty( $announce_nbr_display ) ) $announce_nbr_display = 10; ! if ( empty( $announce_nbr_days ) ) $announce_nbr_days = 365; // Start initial var setup ! ! if ( isset( $HTTP_GET_VARS[POST_FORUM_URL] ) || isset( $HTTP_POST_VARS[POST_FORUM_URL] ) ) { ! $forum_id = ( isset( $HTTP_GET_VARS[POST_FORUM_URL] ) ) ? intval( $HTTP_GET_VARS[POST_FORUM_URL] ) : intval( $HTTP_POST_VARS[POST_FORUM_URL] ); } ! else if ( isset( $HTTP_GET_VARS['forum'] ) ) { ! $forum_id = intval( $HTTP_GET_VARS['forum'] ); } else --- 19,54 ---- * (at your option) any later version. */ ! // ! // Read block Configuration ! // ! $block_config = read_block_config($block_id); $title = $block_config[$block_id]['block_title']; ! $announce_nbr_display = $block_config[$block_id]['announce_nbr_display']['parameter_value']; ! $announce_nbr_days = $block_config[$block_id]['announce_nbr_days']['parameter_value']; ! $announce_display_global = $block_config[$block_id]['announce_display_global']['parameter_value']; ! $announce_display = $block_config[$block_id]['announce_display']['parameter_value']; ! $announce_display_sticky = $block_config[$block_id]['announce_display_sticky']['parameter_value']; ! $announce_display_normal = $block_config[$block_id]['announce_display_normal']['parameter_value']; ! $announce_img_global = $block_config[$block_id]['announce_img_global']['parameter_value']; ! $announce_img = $block_config[$block_id]['announce_img']['parameter_value']; ! $announce_img_sticky = $block_config[$block_id]['announce_img_sticky']['parameter_value']; ! $announce_img_normal = $block_config[$block_id]['announce_img_normal']['parameter_value']; ! $announce_forum = $block_config[$block_id]['announce_forum']['parameter_value']; ! if ( empty($announce_nbr_display) ) $announce_nbr_display = 10; ! if ( empty($announce_nbr_days) ) $announce_nbr_days = 365; + // // Start initial var setup ! // ! if ( isset($HTTP_GET_VARS[POST_FORUM_URL]) || isset($HTTP_POST_VARS[POST_FORUM_URL]) ) { ! $forum_id = ( isset($HTTP_GET_VARS[POST_FORUM_URL]) ) ? intval($HTTP_GET_VARS[POST_FORUM_URL]) : intval($HTTP_POST_VARS[POST_FORUM_URL]); } ! else if ( isset($HTTP_GET_VARS['forum']) ) { ! $forum_id = intval($HTTP_GET_VARS['forum']); } else *************** *** 55,78 **** } // Decide how to order the post display ! ! if ( !empty( $HTTP_POST_VARS['postorder'] ) || !empty( $HTTP_GET_VARS['postorder'] ) ) { ! $post_order = ( !empty( $HTTP_POST_VARS['postorder'] ) ) ? $HTTP_POST_VARS['postorder'] : $HTTP_GET_VARS['postorder']; ! $post_order = htmlspecialchars( $post_order ); } ! $post_time_order = ( $post_order == "asc" ) ? "ASC" : "DESC"; ! $start = ( isset( $HTTP_GET_VARS['start'] ) ) ? intval( $HTTP_GET_VARS['start'] ) : 0; // Grab all the basic data (all topics except announcements) // for this forum ! // Authorization SQL ! $auth_data_sql = get_auth_forum(); ! ! if ( empty( $announce_forum ) ) { $announce_forum = $auth_data_sql; --- 57,81 ---- } + // // Decide how to order the post display ! // ! if ( !empty($HTTP_POST_VARS['postorder']) || !empty($HTTP_GET_VARS['postorder']) ) { ! $post_order = ( !empty($HTTP_POST_VARS['postorder']) ) ? $HTTP_POST_VARS['postorder'] : $HTTP_GET_VARS['postorder']; } ! $post_time_order = ( $post_order == 'asc' ) ? 'ASC' : 'DESC'; ! $start = ( isset($HTTP_GET_VARS['start']) ) ? intval($HTTP_GET_VARS['start']) : 0; + // // Grab all the basic data (all topics except announcements) // for this forum + // ! // // Authorization SQL ! // $auth_data_sql = get_auth_forum(); ! if ( empty($announce_forum) ) { $announce_forum = $auth_data_sql; *************** *** 88,92 **** $t_commas = ','; } - if ( $announce_display == 'TRUE' ) { --- 91,94 ---- *************** *** 94,98 **** $t_commas = ','; } - if ( $announce_display_sticky == 'TRUE' ) { --- 96,99 ---- *************** *** 100,116 **** $t_commas = ','; } - if ( $announce_display_normal == 'TRUE' ) { $topic_type .= $t_commas . POST_NORMAL ; } ! if ( empty( $topic_type ) ) $topic_type = 0; ! ! $sql = "SELECT t.*, u.username, u.user_id, p.*, pt.post_text, pt.post_subject, pt.bbcode_uid ! FROM " . POSTS_TABLE . " p, " . TOPICS_TABLE . " t, " . USERS_TABLE . " u, " . POSTS_TEXT_TABLE . " pt WHERE p.topic_id = t.topic_id ! AND t.topic_type in ( " . $topic_type . " ) ! AND p.post_id = t.topic_first_post_id AND pt.post_id = p.post_id AND u.user_id = p.poster_id --- 101,118 ---- $t_commas = ','; } if ( $announce_display_normal == 'TRUE' ) { $topic_type .= $t_commas . POST_NORMAL ; } + if( empty($topic_type) ) + { + $topic_type = 0; + } ! $sql = "SELECT t.*, u.username, u.user_id, p.*, pt.post_text, pt.post_subject, pt.bbcode_uid, p2.post_time AS last_post_time ! FROM " . POSTS_TABLE . " p, " . TOPICS_TABLE . " t, " . USERS_TABLE . " u, " . POSTS_TEXT_TABLE . " pt, " . POSTS_TABLE . " p2 WHERE p.topic_id = t.topic_id ! AND t.topic_type IN ( " . $topic_type . " ) ! AND p.post_id = t.topic_first_post_id AND pt.post_id = p.post_id AND u.user_id = p.poster_id *************** *** 118,136 **** AND t.forum_id IN ( $auth_data_sql ) AND t.forum_id IN ( $announce_forum ) ORDER BY p.post_time $post_time_order LIMIT $start, " . $announce_nbr_display; ! if ( !( $result = $db->sql_query( $sql ) ) ) { ! message_die( GENERAL_ERROR, 'Could not obtain announce information', '', __LINE__, __FILE__, $sql ); } $postrow = array(); ! while ( $row = $db->sql_fetchrow( $result ) ) { $postrow[] = $row; } ! $total_posts = count( $postrow ); if ( $total_posts == 0 ) --- 120,139 ---- AND t.forum_id IN ( $auth_data_sql ) AND t.forum_id IN ( $announce_forum ) + AND p2.post_id = t.topic_last_post_id ORDER BY p.post_time $post_time_order LIMIT $start, " . $announce_nbr_display; ! if ( !($result = $db->sql_query($sql)) ) { ! mx_message_die(GENERAL_ERROR, 'Could not obtain announce information', '', __LINE__, __FILE__, $sql); } $postrow = array(); ! while( $row = $db->sql_fetchrow($result) ) { $postrow[] = $row; } ! $total_posts = count($postrow); if ( $total_posts == 0 ) *************** *** 138,304 **** $block_rows[$block]['show_title'] = 0; $block_rows[$block]['show_block'] = 0; } ! else { ! for( $i = 0; $i < $total_posts; $i++ ) { ! $poster_id = $postrow[$i]['user_id']; ! $poster = ( $poster_id == ANONYMOUS ) ? $lang['Guest'] : $postrow[$i]['username']; ! $post_date = create_date( $board_config['default_dateformat'], $postrow[$i]['post_time'], $board_config['board_timezone'] ); ! ! $title = $postrow[$i]['topic_title']; ! $bbcode_uid = $postrow[$i]['bbcode_uid']; ! $title = mx_decode( $title, $bbcode_uid ) ; ! ! $message = $postrow[$i]['post_text']; ! $bbcode_uid = $postrow[$i]['bbcode_uid']; ! $message = mx_decode( $message, $bbcode_uid ) ; ! ! $topic_title = ( count( $orig_word ) ) ? preg_replace( $orig_word, $replacement_word, $postrow[$i]['topic_title'] ) : $postrow[$i]['topic_title']; ! $replies = $postrow[$i]['topic_replies']; ! $topic_type = $postrow[$i]['topic_type']; ! ! if ( $topic_type == POST_ANNOUNCE ) ! { ! $topic_type = $lang['Topic_Announcement'] . ' '; ! } ! else if ( $topic_type == POST_STICKY ) ! { ! $topic_type = $lang['Topic_Sticky'] . ' '; ! } ! else ! { ! $topic_type = ''; ! } ! ! if ( $postrow[$i]['topic_vote'] ) { ! $topic_type .= $lang['Topic_Poll'] . ' '; } ! ! if ( $unread_topics ) { ! $folder_image = $folder_new; } ! else { ! $folder_image = $folder; } ! ! $poster_id = $postrow[$i]['user_id']; ! $poster = ( $poster_id == ANONYMOUS ) ? $lang['Guest'] : $postrow[$i]['username']; ! ! $annoucement_image = $announce_img_normal; ! ! if ( $postrow[$i]['topic_status'] == TOPIC_MOVED ) { ! $topic_type = $lang['Topic_Moved'] . ' '; ! $topic_id = $postrow[$i]['topic_moved_id']; ! ! $folder_image = $images['folder']; ! $folder_alt = $lang['Topics_Moved']; ! $newest_post_img = ''; } else { ! if ( $postrow[$i]['topic_type'] == POST_GLOBAL_ANNOUNCE ) ! { ! $folder = $images['folder_announce']; ! $folder_new = $images['folder_announce_new']; ! $annoucement_image = $announce_img_global; ! } ! else if ( $postrow[$i]['topic_type'] == POST_ANNOUNCE ) ! { ! $folder = $images['folder_announce']; ! $folder_new = $images['folder_announce_new']; ! $annoucement_image = $announce_img; ! } ! else if ( $postrow[$i]['topic_type'] == POST_STICKY ) ! { ! $folder = $images['folder_sticky']; ! $folder_new = $images['folder_sticky_new']; ! $annoucement_image = $announce_img_sticky; ! } ! else if ( $postrow[$i]['topic_status'] == TOPIC_LOCKED ) { ! $folder = $images['folder_locked']; ! $folder_new = $images['folder_locked_new']; } else { ! if ( $replies >= $board_config['hot_threshold'] ) ! { ! $folder = $images['folder_hot']; ! $folder_new = $images['folder_hot_new']; ! } ! else ! { ! $folder = $images['folder']; ! $folder_new = $images['folder_new']; ! } } ! ! $newest_post_img = ''; ! if ( $userdata['session_logged_in'] ) { ! if ( $postrow[$i]['post_time'] > $userdata['user_lastvisit'] ) { ! if ( !empty( $tracking_topics ) || !empty( $tracking_forums ) || isset( $HTTP_COOKIE_VARS[$board_config['cookie_name'] . '_f_all'] ) ) { ! $unread_topics = true; ! ! if ( !empty( $tracking_topics[$topic_id] ) ) ! { ! if ( $tracking_topics[$topic_id] >= $postrow[$i]['post_time'] ) ! { ! $unread_topics = false; ! } ! } ! ! if ( !empty( $tracking_forums[$forum_id] ) ) ! { ! if ( $tracking_forums[$forum_id] >= $postrow[$i]['post_time'] ) ! { ! $unread_topics = false; ! } ! } ! ! if ( isset( $HTTP_COOKIE_VARS[$board_config['cookie_name'] . '_f_all'] ) ) { ! if ( $HTTP_COOKIE_VARS[$board_config['cookie_name'] . '_f_all'] >= $postrow[$i]['post_time'] ) ! { ! $unread_topics = false; ! } } ! ! if ( $unread_topics ) { ! $folder_image = $folder_new; ! $folder_alt = $lang['New_posts']; ! ! $newest_post_img = '<a href="' . append_sid( "viewtopic.$phpEx?" . POST_TOPIC_URL . "=$topic_id&view=newest" ) . '"><img src="' . $images['icon_newest_reply'] . '" alt="' . $lang['View_newest_post'] . '" title="' . $lang['View_newest_post'] . '" border="0" /></a> '; } ! else { ! $folder_image = $folder; ! $folder_alt = ( $postrow[$i]['topic_status'] == TOPIC_LOCKED ) ? $lang['Topic_locked'] : $lang['No_new_posts']; ! ! $newest_post_img = ''; } } ! else { $folder_image = $folder_new; ! $folder_alt = ( $postrow[$i]['topic_status'] == TOPIC_LOCKED ) ? $lang['Topic_locked'] : $lang['New_posts']; ! ! $newest_post_img = '<a href="' . append_sid( "viewtopic.$phpEx?" . POST_TOPIC_URL . "=$topic_id&view=newest" ) . '"><img src="' . $images['icon_newest_reply'] . '" alt="' . $lang['View_newest_post'] . '" title="' . $lang['View_newest_post'] . '" border="0" /></a> '; } } else { ! $folder_image = $folder; ! $folder_alt = ( $postrow[$i]['topic_status'] == TOPIC_LOCKED ) ? $lang['Topic_locked'] : $lang['No_new_posts']; ! ! $newest_post_img = ''; } } --- 141,290 ---- $block_rows[$block]['show_title'] = 0; $block_rows[$block]['show_block'] = 0; + return; } ! ! for( $i = 0; $i < $total_posts; $i++ ) { ! $poster_id = $postrow[$i]['user_id']; ! $poster = ( $poster_id == ANONYMOUS ) ? $lang['Guest'] : $postrow[$i]['username']; ! $post_date = create_date($board_config['default_dateformat'], $postrow[$i]['post_time'], $board_config['board_timezone']); ! ! $title = $postrow[$i]['topic_title']; ! $bbcode_uid = $postrow[$i]['bbcode_uid']; ! $title = mx_decode($title, $bbcode_uid); ! ! $message = $postrow[$i]['post_text']; ! $bbcode_uid = $postrow[$i]['bbcode_uid']; ! $message = mx_decode($message, $bbcode_uid ); ! ! $topic_title = ( count($orig_word) ) ? preg_replace($orig_word, $replacement_word, $postrow[$i]['topic_title']) : $postrow[$i]['topic_title']; ! $replies = $postrow[$i]['topic_replies']; ! $topic_type = $postrow[$i]['topic_type']; ! ! if ( $topic_type == POST_ANNOUNCE ) { ! $topic_type = $lang['Topic_Announcement'] . ' '; ! } ! else if ( $topic_type == POST_STICKY ) ! { ! $topic_type = $lang['Topic_Sticky'] . ' '; ! } ! else ! { ! $topic_type = ''; ! } ! ! if ( $postrow[$i]['topic_vote'] ) ! { ! $topic_type .= $lang['Topic_Poll'] . ' '; ! } ! ! $poster_id = $postrow[$i]['user_id']; ! $poster = ( $poster_id == ANONYMOUS ) ? $lang['Guest'] : $postrow[$i]['username']; ! ! $annoucement_image = $announce_img_normal; ! ! if ( $postrow[$i]['topic_status'] == TOPIC_MOVED ) ! { ! $topic_type = $lang['Topic_Moved'] . ' '; ! $topic_id = $postrow[$i]['topic_moved_id']; ! ! $folder_image = $images['folder']; ! $folder_alt = $lang['Topics_Moved']; ! $newest_post_img = ''; ! } ! else ! { ! if ( $postrow[$i]['topic_type'] == POST_GLOBAL_ANNOUNCE ) { ! $folder = $images['folder_announce']; ! $folder_new = $images['folder_announce_new']; ! $annoucement_image = $announce_img_global; } ! else if ( $postrow[$i]['topic_type'] == POST_ANNOUNCE ) { ! $folder = $images['folder_announce']; ! $folder_new = $images['folder_announce_new']; ! $annoucement_image = $announce_img; } ! else if ( $postrow[$i]['topic_type'] == POST_STICKY ) { ! $folder = $images['folder_sticky']; ! $folder_new = $images['folder_sticky_new']; ! $annoucement_image = $announce_img_sticky; } ! else if ( $postrow[$i]['topic_status'] == TOPIC_LOCKED ) { ! $folder = $images['folder_locked']; ! $folder_new = $images['folder_locked_new']; } else { ! if ( $replies >= $board_config['hot_threshold'] ) { ! $folder = $images['folder_hot']; ! $folder_new = $images['folder_hot_new']; } else { ! $folder = $images['folder']; ! $folder_new = $images['folder_new']; } ! } ! ! $newest_post_img = ''; ! if ( $userdata['session_logged_in'] ) ! { ! if ( $postrow[$i]['last_post_time'] > $userdata['user_lastvisit'] ) { ! if ( !empty($tracking_topics) || !empty($tracking_forums) || isset($HTTP_COOKIE_VARS[$board_config['cookie_name'] . '_f_all']) ) { ! $unread_topics = true; ! ! if ( !empty($tracking_topics[$topic_id]) ) { ! if ( $tracking_topics[$topic_id] >= $postrow[$i]['last_post_time'] ) { ! $unread_topics = false; } ! } ! ! if ( !empty($tracking_forums[$forum_id]) ) ! { ! if ( $tracking_forums[$forum_id] >= $postrow[$i]['last_post_time'] ) { ! $unread_topics = false; } ! } ! ! if ( isset($HTTP_COOKIE_VARS[$board_config['cookie_name'] . '_f_all']) ) ! { ! if ( $HTTP_COOKIE_VARS[$board_config['cookie_name'] . '_f_all'] >= $postrow[$i]['last_post_time'] ) { ! $unread_topics = false; } } ! ! if ( $unread_topics ) { $folder_image = $folder_new; ! $folder_alt = $lang['New_posts']; ! ! $newest_post_img = '<a href="' . append_sid(PHPBB_URL . "viewtopic.$phpEx?" . POST_TOPIC_URL . "=$topic_id&view=newest") . '"><img src="' . $images['icon_newest_reply'] . '" alt="' . $lang['View_newest_post'] . '" title="' . $lang['View_newest_post'] . '" border="0" /></a> '; ! } ! else ! { ! $folder_image = $folder; ! $folder_alt = ( $postrow[$i]['topic_status'] == TOPIC_LOCKED ) ? $lang['Topic_locked'] : $lang['No_new_posts']; ! ! $newest_post_img = ''; } } else { ! $folder_image = $folder_new; ! $folder_alt = ( $postrow[$i]['topic_status'] == TOPIC_LOCKED ) ? $lang['Topic_locked'] : $lang['New_posts']; ! ! $newest_post_img = '<a href="' . append_sid(PHPBB_URL . "viewtopic.$phpEx?" . POST_TOPIC_URL . "=$topic_id&view=newest") . '"><img src="' . $images['icon_newest_reply'] . '" alt="' . $lang['View_newest_post'] . '" title="' . $lang['View_newest_post'] . '" border="0" /></a> '; } } *************** *** 307,367 **** $folder_image = $folder; $folder_alt = ( $postrow[$i]['topic_status'] == TOPIC_LOCKED ) ? $lang['Topic_locked'] : $lang['No_new_posts']; ! $newest_post_img = ''; } } ! ! $replies = $postrow[$i]['topic_replies']; ! $views = $postrow[$i]['topic_views']; ! $first_post_time = create_date( $board_config['default_dateformat'], $postrow[$i]['topic_time'], $board_config['board_timezone'] ); ! $last_post_time = create_date( $board_config['default_dateformat'], $postrow[$i]['post_time'], $board_config['board_timezone'] ); ! ! $last_post_author = ( $postrow[$i]['id2'] == ANONYMOUS ) ? ( ( $postrow[$i]['post_username2'] != '' ) ? $postrow[$i]['post_username2'] . ' ' : $lang['Guest'] . ' ' ) : '<a href="' . append_sid( "profile.$phpEx?mode=viewprofile&" . POST_USERS_URL . '=' . $postrow[$i]['id2'] ) . '">' . $postrow[$i]['user2'] . '</a>'; ! $last_post_img = '<a href="' . append_sid( PHPBB_URL . "viewtopic.$phpEx?" . POST_POST_URL . '=' . $postrow[$i]['topic_last_post_id'] ) . '#' . $postrow[$i]['topic_last_post_id'] . '"><img src="' . PHPBB_URL . $images['icon_latest_reply'] . '" alt="' . $lang['View_latest_post'] . '" title="' . $lang['View_latest_post'] . '" border="0" /></a>'; ! ! $last_post_url = append_sid( PHPBB_URL . "viewtopic.$phpEx?" . POST_POST_URL . '=' . $postrow[$i]['topic_last_post_id'] . '#' . $postrow[$i]['topic_last_post_id'] ); ! ! $template->assign_block_vars( "postrow", array( 'TITLE' => $title, ! 'MESSAGE' => $message, ! 'POST_DATE' => $post_date, ! 'POST_SUBJECT' => $post_subject, ! 'POSTER_NAME' => $poster, ! 'POSTER_ID' => $poster_id, ! 'TOPIC_ID' => $postrow[$i]['topic_id'], ! 'SIGNATURE' => $user_sig, ! 'FOLDER_IMG' => $folder_image, ! 'IMAGE' => TEMPLATE_ROOT_PATH . 'images/' . $annoucement_image, ! ! 'U_URL' => $last_post_url, ! ! 'REPLIES' => $replies, ! 'VIEWS' => $views, ! 'FIRST_POST_TIME' => $first_post_time, ! 'LAST_POST_TIME' => $last_post_time, ! 'LAST_POST_AUTHOR' => $last_post_author, ! 'LAST_POST_IMG' => $last_post_img, ! ! 'L_AUTHOR' => $lang['Author'], ! 'L_POSTED' => $lang['Posted'], ! 'L_REPLIES' => $lang['Replies'], ! 'L_VIEWS' => $lang['Views'], ! 'L_POSTS' => $lang['Posts'], ! 'L_LASTPOST' => $lang['Last_Post'], ! ! 'L_TOPIC_FOLDER_ALT' => $folder_alt ! ) ); } ! ! $template->set_filenames( array( ! "body_announce" => "mx_announce.tpl" ) ! ); ! ! $template->assign_vars( array( 'BLOCK_SIZE' => ( !empty( $block_size ) ? $block_size : '100%' ), ! 'U_URL' => append_sid( 'index.' . $phpEx . '?block_id=' . $block_id ), ! 'U_PHPBB_ROOT_PATH' => PHPBB_URL, ! 'TEMPLATE_ROOT_PATH' => TEMPLATE_ROOT_PATH ! ) ); ! ! $template->pparse( "body_announce" ); } ?> \ No newline at end of file --- 293,363 ---- $folder_image = $folder; $folder_alt = ( $postrow[$i]['topic_status'] == TOPIC_LOCKED ) ? $lang['Topic_locked'] : $lang['No_new_posts']; ! $newest_post_img = ''; } } ! else ! { ! $folder_image = $folder; ! $folder_alt = ( $postrow[$i]['topic_status'] == TOPIC_LOCKED ) ? $lang['Topic_locked'] : $lang['No_new_posts']; ! ! $newest_post_img = ''; ! } } ! ! $replies = $postrow[$i]['topic_replies']; ! $views = $postrow[$i]['topic_views']; ! $first_post_time = create_date($board_config['default_dateformat'], $postrow[$i]['topic_time'], $board_config['board_timezone']); ! $last_post_time = create_date($board_config['default_dateformat'], $postrow[$i]['last_post_time'], $board_config['board_timezone']); ! ! $last_post_author = ( $postrow[$i]['id2'] == ANONYMOUS ) ? ( ( $postrow[$i]['post_username2'] != '' ) ? $postrow[$i]['post_username2'] . ' ' : $lang['Guest'] . ' ' ) : '<a href="' . append_sid(PHPBB_URL . "profile.$phpEx?mode=viewprofile&" . POST_USERS_URL . '=' . $postrow[$i]['id2']) . '">' . $postrow[$i]['user2'] . '</a>'; ! $last_post_img = '<a href="' . append_sid(PHPBB_URL . "viewtopic.$phpEx?" . POST_POST_URL . '=' . $postrow[$i]['topic_last_post_id']) . '#' . $postrow[$i]['topic_last_post_id'] . '"><img src="' . PHPBB_URL . $images['icon_latest_reply'] . '" alt="' . $lang['View_latest_post'] . '" title="' . $lang['View_latest_post'] . '" border="0" /></a>'; ! ! $last_post_url = append_sid(PHPBB_URL . "viewtopic.$phpEx?" . POST_POST_URL . '=' . $postrow[$i]['topic_last_post_id'] . '#' . $postrow[$i]['topic_last_post_id']); ! ! $template->assign_block_vars("postrow", array( ! 'TITLE' => $title, ! 'MESSAGE' => $message, ! 'POST_DATE' => $post_date, ! 'POST_SUBJECT' => $post_subject, ! 'POSTER_NAME' => $poster, ! 'POSTER_ID' => $poster_id, ! 'TOPIC_ID' => $postrow[$i]['topic_id'], ! 'SIGNATURE' => $user_sig, ! 'FOLDER_IMG' => $folder_image, ! 'IMAGE' => TEMPLATE_ROOT_PATH . 'images/' . $annoucement_image, ! ! 'U_URL' => $last_post_url, ! ! 'REPLIES' => $replies, ! 'VIEWS' => $views, ! 'FIRST_POST_TIME' => $first_post_time, ! 'LAST_POST_TIME' => $last_post_time, ! 'LAST_POST_AUTHOR' => $last_post_author, ! 'LAST_POST_IMG' => $last_post_img, ! ! 'L_AUTHOR' => $lang['Author'], ! 'L_POSTED' => $lang['Posted'], ! 'L_REPLIES' => $lang['Replies'], ! 'L_VIEWS' => $lang['Views'], ! 'L_POSTS' => $lang['Posts'], ! 'L_LASTPOST' => $lang['Last_Post'], ! ! 'L_TOPIC_FOLDER_ALT' => $folder_alt ! )); ! } + + $template->set_filenames(array( + 'body_announce' => 'mx_announce.tpl') + ); + + $template->assign_vars(array( + 'BLOCK_SIZE' => ( !empty( $block_size ) ? $block_size : '100%' ), + 'U_PHPBB_ROOT_PATH' => PHPBB_URL, + 'TEMPLATE_ROOT_PATH' => TEMPLATE_ROOT_PATH + )); + + $template->pparse('body_announce'); + ?> \ No newline at end of file |
|
From: Markus P. <mar...@us...> - 2005-04-19 15:55:49
|
Update of /cvsroot/mxbb/core/modules/mx_coreblocks/templates/subSilver In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv2884/templates/subSilver Modified Files: mx_announce.tpl Log Message: Fixed some named array with non-quoted indexes and code layout. Fixed last post date in announcement block. Index: mx_announce.tpl =================================================================== RCS file: /cvsroot/mxbb/core/modules/mx_coreblocks/templates/subSilver/mx_announce.tpl,v retrieving revision 1.6 retrieving revision 1.7 diff -C2 -d -r1.6 -r1.7 *** mx_announce.tpl 6 Mar 2005 01:10:16 -0000 1.6 --- mx_announce.tpl 19 Apr 2005 15:55:39 -0000 1.7 *************** *** 1,29 **** <!-- BEGIN postrow --> ! <table width="{BLOCK_SIZE}" border="0" cellpadding="4" cellspacing="0" class="forumline"> ! <tr> ! <td class="row1" colspan="3"> ! <table cellSpacing="0" cellPadding="4" width="100%" border="0"> ! <tbody> ! <tr> ! <td class="row1"><A href="{postrow.U_URL}"> ! <img alt="{postrow.TITLE}" hspace="5" src="{postrow.IMAGE}" align="right" vspace="5" border="1"></a> ! <a href="{postrow.U_URL}"><b>{postrow.TITLE}</b></a><br><font ! size=-1><span class="postbody">{postrow.MESSAGE}</span></font></td></tr></tbody></table> ! </td> ! </tr> ! <tr> ! <td class="row1" width="100%" valign="top" colspan="3"> ! <table width="100%" border="0" cellspacing="1" cellpadding="0"> ! <tr> ! <td class="row2" align="center" valign="middle"><span class="gensmall">{postrow.L_AUTHOR} <a href="{U_PHPBB_ROOT_PATH}profile.php?mode=viewprofile&u={postrow.POSTER_ID}">{postrow.POSTER_NAME}</a></span></td> ! <td class="row2" align="center" valign="middle"><span class="gensmall">{postrow.L_POSTED} <br /> {postrow.FIRST_POST_TIME}</span></td> ! <td class="row2" align="center" valign="middle"><span class="postdetails">{postrow.L_REPLIES} <br /> {postrow.REPLIES}</span></td> ! <td class="row2" align="center" valign="middle"><span class="postdetails">{postrow.L_VIEWS} <br /> {postrow.VIEWS}</span></td> ! <td class="row2" align="center" valign="middle"><span class="postdetails">{postrow.L_LASTPOST} <br /> {postrow.LAST_POST_TIME}{postrow.LAST_POST_AUTHOR} {postrow.LAST_POST_IMG}</span></td> ! </tr> ! </table></td> ! </tr> ! </table> <!-- END postrow --> - --- 1,42 ---- <!-- BEGIN postrow --> ! <table width="{BLOCK_SIZE}" border="0" cellpadding="4" cellspacing="0" class="forumline"> ! <tr> ! <td class="row1"> ! <table width="100%" border="0" cellpadding="4" cellspacing="0"> ! <tbody> ! <tr> ! <td class="row1"> ! <p> ! <a href="{postrow.U_URL}"> ! <img src="{postrow.IMAGE}" align="right" hspace="5" vspace="5" border="1" title="{postrow.TITLE}" alt="{postrow.TITLE}" /> ! </a> ! <a href="{postrow.U_URL}" class="topictitle"> ! <img src="{postrow.TOPIC_FOLDER_IMG}" width="19" height="18" ! alt="{postrow.L_TOPIC_FOLDER_ALT}" title="{postrow.L_TOPIC_FOLDER_ALT}" ! border="0" align="absmiddle" /> ! {postrow.TITLE} ! </a> ! </p> ! <span class="postbody">{postrow.MESSAGE}</span> ! </td> ! </tr> ! </tbody> ! </table> ! </td> ! </tr> ! <tr> ! <td class="row1" width="100%" valign="top"> ! <table width="100%" border="0" cellpadding="2" cellspacing="1"> ! <tr> ! <td class="row2" align="center" valign="middle"><span class="gensmall">{postrow.L_AUTHOR} <a href="{U_PHPBB_ROOT_PATH}profile.php?mode=viewprofile&u={postrow.POSTER_ID}">{postrow.POSTER_NAME}</a></span></td> ! <td class="row2" align="center" valign="middle"><span class="gensmall">{postrow.L_POSTED} <br /> {postrow.FIRST_POST_TIME}</span></td> ! <td class="row2" align="center" valign="middle"><span class="postdetails">{postrow.L_REPLIES} <br /> {postrow.REPLIES}</span></td> ! <td class="row2" align="center" valign="middle"><span class="postdetails">{postrow.L_VIEWS} <br /> {postrow.VIEWS}</span></td> ! <td class="row2" align="center" valign="middle"><span class="postdetails">{postrow.L_LASTPOST} <br /> {postrow.LAST_POST_TIME}{postrow.LAST_POST_AUTHOR} {postrow.LAST_POST_IMG}</span></td> ! </tr> ! </table> ! </td> ! </tr> </table> + <br clear="all" /> <!-- END postrow --> |
|
From: Markus P. <mar...@us...> - 2005-04-19 13:52:09
|
Update of /cvsroot/mxbb/core In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv2237 Modified Files: index.php Log Message: Fixed some named array with non-quoted indexes. Index: index.php =================================================================== RCS file: /cvsroot/mxbb/core/index.php,v retrieving revision 1.31 retrieving revision 1.32 diff -C2 -d -r1.31 -r1.32 *** index.php 16 Apr 2005 21:51:35 -0000 1.31 --- index.php 19 Apr 2005 13:51:54 -0000 1.32 *************** *** 23,29 **** //define('MX_DEBUG', 1); ! define( 'IN_PORTAL', 1 ); ! $mx_root_path = "./"; include($mx_root_path . 'extension.inc'); --- 23,29 ---- //define('MX_DEBUG', 1); ! define('IN_PORTAL', 1); ! $mx_root_path = './'; include($mx_root_path . 'extension.inc'); *************** *** 52,56 **** $mx_session_time = isset($HTTP_SESSION_VARS['mx_session_recached']) ? $HTTP_SESSION_VARS['mx_session_recached'] : $userdata['session_start']; ! if ( empty( $HTTP_SESSION_VARS['mx_pages']['page_' . $page_id] ) || $portal_config['portal_recached'] > $mx_session_time ) { $HTTP_SESSION_VARS['mx_session_recached'] = $portal_config['portal_recached']; --- 52,56 ---- $mx_session_time = isset($HTTP_SESSION_VARS['mx_session_recached']) ? $HTTP_SESSION_VARS['mx_session_recached'] : $userdata['session_start']; ! if ( empty($HTTP_SESSION_VARS['mx_pages']['page_' . $page_id]) || $portal_config['portal_recached'] > $mx_session_time ) { $HTTP_SESSION_VARS['mx_session_recached'] = $portal_config['portal_recached']; *************** *** 80,89 **** $is_auth_ary = page_auth(AUTH_VIEW, $userdata, $page_row['page_auth_view'], $page_row['page_auth_view_group']); ! if ( !$is_auth_ary[auth_view] && $userdata['session_logged_in'] ) { $message = empty($lang['Page_Not_Authorised']) ? "Sorry, but you don't have privilege to access this page." : $lang['Page_Not_Authorised']; mx_message_die(GENERAL_MESSAGE, $message, '', __LINE__, __FILE__, ''); } ! elseif ( !$is_auth_ary[auth_view] && !$userdata['session_logged_in'] ) { mx_redirect(append_sid($mx_root_path . "login.$phpEx?redirect=" . mx_this_url(), true)); --- 80,89 ---- $is_auth_ary = page_auth(AUTH_VIEW, $userdata, $page_row['page_auth_view'], $page_row['page_auth_view_group']); ! if ( !$is_auth_ary['auth_view'] && $userdata['session_logged_in'] ) { $message = empty($lang['Page_Not_Authorised']) ? "Sorry, but you don't have privilege to access this page." : $lang['Page_Not_Authorised']; mx_message_die(GENERAL_MESSAGE, $message, '', __LINE__, __FILE__, ''); } ! elseif ( !$is_auth_ary['auth_view'] && !$userdata['session_logged_in'] ) { mx_redirect(append_sid($mx_root_path . "login.$phpEx?redirect=" . mx_this_url(), true)); *************** *** 171,175 **** // Block view auth ----------------------------------------------------------------------------------------------------- ! $is_auth_ary = block_auth( AUTH_VIEW, $mx_block_id, $userdata, $block_rows[$block]['auth_view'], $block_rows[$block]['auth_view_group'] ); if ( ($is_auth_ary['auth_view'] && $block_rows[$block]['show_block'] == 1) || $is_auth_ary['auth_mod'] ) --- 171,175 ---- // Block view auth ----------------------------------------------------------------------------------------------------- ! $is_auth_ary = block_auth(AUTH_VIEW, $mx_block_id, $userdata, $block_rows[$block]['auth_view'], $block_rows[$block]['auth_view_group']); if ( ($is_auth_ary['auth_view'] && $block_rows[$block]['show_block'] == 1) || $is_auth_ary['auth_mod'] ) *************** *** 188,192 **** // Pass block data ! if ( $block_rows[$block]['show_block'] == 1 || $is_auth_ary[auth_mod] ) { $layouttemplate->assign_block_vars('layout_column.blocks', array( --- 188,192 ---- // Pass block data ! if ( $block_rows[$block]['show_block'] == 1 || $is_auth_ary['auth_mod'] ) { $layouttemplate->assign_block_vars('layout_column.blocks', array( *************** *** 230,235 **** $mx_block_edit = false; ! $is_auth_ary = array(); ! $is_auth_ary = block_auth( AUTH_EDIT, $mx_block_id , $userdata, $block_rows[$block]['auth_edit'], $block_rows[$block]['auth_edit_group'] ); if ( ( ($is_auth_ary['auth_edit'] && $block_rows[$block]['show_block'] == 1 ) || $is_auth_ary['auth_mod']) ) --- 230,234 ---- $mx_block_edit = false; ! $is_auth_ary = block_auth(AUTH_EDIT, $mx_block_id , $userdata, $block_rows[$block]['auth_edit'], $block_rows[$block]['auth_edit_group']); if ( ( ($is_auth_ary['auth_edit'] && $block_rows[$block]['show_block'] == 1 ) || $is_auth_ary['auth_mod']) ) *************** *** 242,264 **** $s_hidden_fields .= '<input type="hidden" name="portalpage" value="' . $page_id . '" />'; $s_hidden_fields .= '<input type="hidden" name="mode" value="setting" />'; ! $s_hidden_fields .= '<input type="hidden" name="f" value="' . intval( $HTTP_GET_VARS['f'] ) . '" />'; ! $s_hidden_fields .= '<input type="hidden" name="t" value="' . intval( $HTTP_GET_VARS['t'] ) . '" />'; ! $s_hidden_fields .= '<input type="hidden" name="p" value="' . intval( $HTTP_GET_VARS['p'] ) . '" />'; // Switch between different block types $block_edit_img = ( ( $block_file == 'mx_multiple_blocks.php' ) ? 'block_edit_split.gif' : ( $block_file == 'mx_textblock_blog.php' ? 'block_edit_admin.gif' : 'block_edit.gif' ) ) ; ! $split_admin_file = !empty( $block_rows[$block]['function_admin'] ) ? $block_rows[$block]['function_admin'] : 'admin/admin_mx_block.php'; // Dynamic Block Itself if ( !empty($dynamic_main_block_id) ) { ! $is_dynamic_auth_ary = array(); ! $is_dynamic_auth_ary = block_auth( AUTH_EDIT, $dynamic_main_block_id , $userdata, $dynamic_block_config[$dynamic_main_block_id]['auth_edit'], $dynamic_block_config[$dynamic_main_block_id]['auth_edit_group'] ); if ( ($is_dynamic_auth_ary['auth_edit'] || $is_dynamic_auth_ary['auth_mod']) ) { ! $block_desc = !empty( $dynamic_block_config[$dynamic_main_block_id]['block_desc'] ) ? ' (' . $dynamic_block_config[$dynamic_main_block_id]['block_desc'] . ')' : ''; ! $edit_url = append_sid( $mx_root_path . 'admin/admin_mx_block.php' . "?sid=" . $userdata['session_id'] ); $edit_img = '<input type="image" class ="editblock" src="' . PORTAL_URL . TEMPLATE_ROOT_PATH . 'images/block_icons/' . 'block_edit_admin.gif' . '" alt="' . $lang['Block_Edit'] . $block_rows[$block]['block_id'] . '" title="' . $lang['Block_Edit'] . ' :: ' . $dynamic_block_config[$dynamic_main_block_id]['block_title'] . $block_desc . '">'; --- 241,262 ---- $s_hidden_fields .= '<input type="hidden" name="portalpage" value="' . $page_id . '" />'; $s_hidden_fields .= '<input type="hidden" name="mode" value="setting" />'; ! $s_hidden_fields .= '<input type="hidden" name="f" value="' . intval($HTTP_GET_VARS['f']) . '" />'; ! $s_hidden_fields .= '<input type="hidden" name="t" value="' . intval($HTTP_GET_VARS['t']) . '" />'; ! $s_hidden_fields .= '<input type="hidden" name="p" value="' . intval($HTTP_GET_VARS['p']) . '" />'; // Switch between different block types $block_edit_img = ( ( $block_file == 'mx_multiple_blocks.php' ) ? 'block_edit_split.gif' : ( $block_file == 'mx_textblock_blog.php' ? 'block_edit_admin.gif' : 'block_edit.gif' ) ) ; ! $split_admin_file = !empty($block_rows[$block]['function_admin']) ? $block_rows[$block]['function_admin'] : 'admin/admin_mx_block.php'; // Dynamic Block Itself if ( !empty($dynamic_main_block_id) ) { ! $is_dynamic_auth_ary = block_auth(AUTH_EDIT, $dynamic_main_block_id , $userdata, $dynamic_block_config[$dynamic_main_block_id]['auth_edit'], $dynamic_block_config[$dynamic_main_block_id]['auth_edit_group']); if ( ($is_dynamic_auth_ary['auth_edit'] || $is_dynamic_auth_ary['auth_mod']) ) { ! $block_desc = !empty($dynamic_block_config[$dynamic_main_block_id]['block_desc']) ? ' (' . $dynamic_block_config[$dynamic_main_block_id]['block_desc'] . ')' : ''; ! $edit_url = append_sid($mx_root_path . "admin/admin_mx_block.php?sid=" . $userdata['session_id']); $edit_img = '<input type="image" class ="editblock" src="' . PORTAL_URL . TEMPLATE_ROOT_PATH . 'images/block_icons/' . 'block_edit_admin.gif' . '" alt="' . $lang['Block_Edit'] . $block_rows[$block]['block_id'] . '" title="' . $lang['Block_Edit'] . ' :: ' . $dynamic_block_config[$dynamic_main_block_id]['block_title'] . $block_desc . '">'; *************** *** 267,271 **** $layouttemplate->assign_block_vars('layout_column.blocks.edit', array( ! 'BLOCK_SIZE' => ( !empty( $block_size ) ? $block_size : '100%' ), 'L_TITLE' => $title, 'L_DESC' => $b_description, --- 265,269 ---- $layouttemplate->assign_block_vars('layout_column.blocks.edit', array( ! 'BLOCK_SIZE' => ( !empty($block_size) ? $block_size : '100%' ), 'L_TITLE' => $title, 'L_DESC' => $b_description, *************** *** 280,285 **** } ! $block_desc = !empty( $block_rows[$block]['block_desc'] ) ? ' (' . $block_rows[$block]['block_desc'] . ')' : ''; ! $edit_url = append_sid( $mx_root_path . $split_admin_file . "?sid=" . $userdata['session_id'] ); $edit_img = '<input type="image" class ="editblock" src="' . PORTAL_URL . TEMPLATE_ROOT_PATH . 'images/block_icons/' . $block_edit_img . '" alt="' . $lang['Block_Edit'] . ' :: ' . $block_rows[$block]['block_title'] . $block_desc . '" title="' . $lang['Block_Edit'] . ' :: ' . $block_rows[$block]['block_title'] . $block_desc . '">'; --- 278,283 ---- } ! $block_desc = !empty($block_rows[$block]['block_desc']) ? ' (' . $block_rows[$block]['block_desc'] . ')' : ''; ! $edit_url = append_sid($mx_root_path . $split_admin_file . "?sid=" . $userdata['session_id']); $edit_img = '<input type="image" class ="editblock" src="' . PORTAL_URL . TEMPLATE_ROOT_PATH . 'images/block_icons/' . $block_edit_img . '" alt="' . $lang['Block_Edit'] . ' :: ' . $block_rows[$block]['block_title'] . $block_desc . '" title="' . $lang['Block_Edit'] . ' :: ' . $block_rows[$block]['block_title'] . $block_desc . '">'; *************** *** 287,291 **** $layouttemplate->assign_block_vars('layout_column.blocks.edit', array( ! 'BLOCK_SIZE' => ( !empty( $block_size ) ? $block_size : '100%' ), 'L_TITLE' => $title, 'L_DESC' => $b_description, --- 285,289 ---- $layouttemplate->assign_block_vars('layout_column.blocks.edit', array( ! 'BLOCK_SIZE' => ( !empty($block_size) ? $block_size : '100%' ), 'L_TITLE' => $title, 'L_DESC' => $b_description, *************** *** 308,324 **** // Switch: Edit Block ! $layouttemplate->assign_block_vars( 'layout_column.blocks.edit.switch_edit_' . ( $edit_on ? 'on' : 'off' ), array() ); } // End Edit auth // Switch: show block header ------------------- ! if ( $block_rows[$block]['show_block'] == 1 && ( $mx_block_edit || $block_rows[$block]['show_title'] == 1 ) || $is_auth_ary[auth_mod] ) { $layouttemplate->assign_block_vars('layout_column.blocks.block_header', array()); // Switch: show title ------------------- ! if ( $block_rows[$block]['show_title'] == 1 || $is_auth_ary[auth_mod] ) { ! $this_block_title = $block_rows[$block]['show_title'] == 0 && $is_auth_ary[auth_mod] ? '(' . $block_rows[$block]['block_title'] . ')' : $block_rows[$block]['block_title']; $layouttemplate->assign_block_vars('layout_column.blocks.show_title', array( 'L_TITLE' => $this_block_title, --- 306,322 ---- // Switch: Edit Block ! $layouttemplate->assign_block_vars('layout_column.blocks.edit.switch_edit_' . ( $edit_on ? 'on' : 'off' ), array()); } // End Edit auth // Switch: show block header ------------------- ! if ( $block_rows[$block]['show_block'] == 1 && ( $mx_block_edit || $block_rows[$block]['show_title'] == 1 ) || $is_auth_ary['auth_mod'] ) { $layouttemplate->assign_block_vars('layout_column.blocks.block_header', array()); // Switch: show title ------------------- ! if ( $block_rows[$block]['show_title'] == 1 || $is_auth_ary['auth_mod'] ) { ! $this_block_title = $block_rows[$block]['show_title'] == 0 && $is_auth_ary['auth_mod'] ? '(' . $block_rows[$block]['block_title'] . ')' : $block_rows[$block]['block_title']; $layouttemplate->assign_block_vars('layout_column.blocks.show_title', array( 'L_TITLE' => $this_block_title, |
|
From: Markus P. <mar...@us...> - 2005-04-17 18:28:43
|
Update of /cvsroot/mxbb/core/install In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv17118 Modified Files: mx_install.php Log Message: Now that I think of it, the new installer shouldn't be versioned as 1.0.x, me thinks. Switched to 2.0.0 ;-) Index: mx_install.php =================================================================== RCS file: /cvsroot/mxbb/core/install/mx_install.php,v retrieving revision 1.44 retrieving revision 1.45 diff -C2 -d -r1.44 -r1.45 *** mx_install.php 16 Apr 2005 22:49:57 -0000 1.44 --- mx_install.php 17 Apr 2005 18:28:35 -0000 1.45 *************** *** 54,58 **** // This is shown in the top right corner of the installation panels. // ! define('INSTALLER_VERSION', '1.0.10'); define('INSTALLER_NAME', 'mxBB-IWizard'); --- 54,58 ---- // This is shown in the top right corner of the installation panels. // ! define('INSTALLER_VERSION', '2.0.0'); define('INSTALLER_NAME', 'mxBB-IWizard'); |
|
From: Markus P. <mar...@us...> - 2005-04-17 10:06:49
|
Update of /cvsroot/mxbb/core/install/db In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv12681 Modified Files: postgres7.php Log Message: Fixed postgres7.php as per changes introduced in phpBB 2.0.14 ;-) Index: postgres7.php =================================================================== RCS file: /cvsroot/mxbb/core/install/db/postgres7.php,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** postgres7.php 6 Apr 2005 06:35:00 -0000 1.1 --- postgres7.php 17 Apr 2005 10:06:40 -0000 1.2 *************** *** 124,127 **** --- 124,128 ---- $query = preg_replace("/LIMIT ([0-9]+),([ 0-9]+)/", "LIMIT \\2 OFFSET \\1", $query); + $query = preg_replace('#(.*WHERE.*)(username|user_email|ban_email) = \'(.*)\'#ise', "\"\\1LOWER(\\2) = '\" . strtolower('\\3') . \"'\"", $query); if( $transaction == BEGIN_TRANSACTION && !$this->in_transaction ) |
|
From: Markus P. <mar...@us...> - 2005-04-16 23:02:08
|
Update of /cvsroot/mxbb/core/language/lang_english In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv22530 Modified Files: lang_admin.php Log Message: Changed "Installation Guide" into "Installation Wizard". Much nicer :-) Index: lang_admin.php =================================================================== RCS file: /cvsroot/mxbb/core/language/lang_english/lang_admin.php,v retrieving revision 1.36 retrieving revision 1.37 diff -C2 -d -r1.36 -r1.37 *** lang_admin.php 13 Apr 2005 21:23:28 -0000 1.36 --- lang_admin.php 16 Apr 2005 23:01:59 -0000 1.37 *************** *** 189,193 **** // Install Process // ! $lang['Welcome_install'] = "Welcome to the mxBB-Portal Installation Guide"; $lang['Install_Instruction'] = "Please, fill out the details requested below. This installation program will create your personalized config.php (in the Portal root directory) and the Portal database with default settings. Once this is done, you'll see a report of all the steps taken (please note mxBB-Portal does not modify your phpBB database in any way). Then, you should login to your board with your administrator username and password and go to the Administration Control Panel to configure your portal upon your own needs. Please note mxBB-Portal will not work by itself, phpBB must already be installed and configured. Thank you for choosing mxBB-Portal."; $lang['Upgrade_Instruction'] = "mxBB-Portal is already installed. Please, make backups of your database now !<br /><br />The next step will modify the structure of your database (please note mxBB-Portal does not modify your phpBB database in any way). If for whatever reason this upgrade procedure fails, there would be no other way to return to your current state. Please, make backups of your database BEFORE proceeding !<br /><br />Once done, click the button below to start the upgrade procedure."; --- 189,193 ---- // Install Process // ! $lang['Welcome_install'] = "Welcome to the mxBB-Portal Installation Wizard"; $lang['Install_Instruction'] = "Please, fill out the details requested below. This installation program will create your personalized config.php (in the Portal root directory) and the Portal database with default settings. Once this is done, you'll see a report of all the steps taken (please note mxBB-Portal does not modify your phpBB database in any way). Then, you should login to your board with your administrator username and password and go to the Administration Control Panel to configure your portal upon your own needs. Please note mxBB-Portal will not work by itself, phpBB must already be installed and configured. Thank you for choosing mxBB-Portal."; $lang['Upgrade_Instruction'] = "mxBB-Portal is already installed. Please, make backups of your database now !<br /><br />The next step will modify the structure of your database (please note mxBB-Portal does not modify your phpBB database in any way). If for whatever reason this upgrade procedure fails, there would be no other way to return to your current state. Please, make backups of your database BEFORE proceeding !<br /><br />Once done, click the button below to start the upgrade procedure."; |
|
From: Markus P. <mar...@us...> - 2005-04-16 22:50:09
|
Update of /cvsroot/mxbb/core/install In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv16244 Modified Files: mx_install.php Log Message: Fixed little bug loading template class during installation. Index: mx_install.php =================================================================== RCS file: /cvsroot/mxbb/core/install/mx_install.php,v retrieving revision 1.43 retrieving revision 1.44 diff -C2 -d -r1.43 -r1.44 *** mx_install.php 16 Apr 2005 22:28:30 -0000 1.43 --- mx_install.php 16 Apr 2005 22:49:57 -0000 1.44 *************** *** 356,360 **** $s_hidden_fields = ''; ! include($mx_root_path . "includes/template.$phpEx"); $template = new Template($mx_root_path . 'install/templates'); page_header_install($lang['Welcome_install'], $lang['Choose_lang_explain']); --- 356,360 ---- $s_hidden_fields = ''; ! include($mx_root_path . "install/includes/template.$phpEx"); $template = new Template($mx_root_path . 'install/templates'); page_header_install($lang['Welcome_install'], $lang['Choose_lang_explain']); *************** *** 472,476 **** '<input type="hidden" name="config_data" value="' . htmlspecialchars($config_data) . '" />'; ! include($mx_root_path . "includes/template.$phpEx"); $template = new Template($mx_root_path . 'install/templates'); page_header_install($lang['Welcome_install'], $instruction_text); --- 472,476 ---- '<input type="hidden" name="config_data" value="' . htmlspecialchars($config_data) . '" />'; ! include($mx_root_path . "install/includes/template.$phpEx"); $template = new Template($mx_root_path . 'install/templates'); page_header_install($lang['Welcome_install'], $instruction_text); *************** *** 620,624 **** $message .= ' <br /> <br />' . $lang['Thanks_for_choosing'] . '<br /> <br />'; ! include($mx_root_path . "includes/template.$phpEx"); $template = new Template($mx_root_path . 'install/templates'); page_header_install($install_title, $message); --- 620,624 ---- $message .= ' <br /> <br />' . $lang['Thanks_for_choosing'] . '<br /> <br />'; ! include($mx_root_path . "install/includes/template.$phpEx"); $template = new Template($mx_root_path . 'install/templates'); page_header_install($install_title, $message); *************** *** 643,647 **** // Create the template for the first installation step. // ! include($mx_root_path . "includes/template.$phpEx"); $template = new Template($mx_root_path . 'install/templates'); --- 643,647 ---- // Create the template for the first installation step. // ! include($mx_root_path . "install/includes/template.$phpEx"); $template = new Template($mx_root_path . 'install/templates'); *************** *** 1038,1042 **** else { ! include($mx_root_path . "includes/template.$phpEx"); $template = new Template($mx_root_path . 'install/templates'); page_header_install($lang['Installation_error'], $message); --- 1038,1042 ---- else { ! include($mx_root_path . "install/includes/template.$phpEx"); $template = new Template($mx_root_path . 'install/templates'); page_header_install($lang['Installation_error'], $message); *************** *** 1415,1419 **** // Send the result to the browser. // ! include($mx_root_path . "includes/template.$phpEx"); $template = new Template($mx_root_path . 'install/templates'); page_header_install('phpInfo()'); --- 1415,1419 ---- // Send the result to the browser. // ! include($mx_root_path . "install/includes/template.$phpEx"); $template = new Template($mx_root_path . 'install/templates'); page_header_install('phpInfo()'); |
|
From: Markus P. <mar...@us...> - 2005-04-16 22:28:39
|
Update of /cvsroot/mxbb/core/install In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv4562 Modified Files: mx_install.php Log Message: Fixed little bug when closing DB sessions used to guess the phpBB installation. Index: mx_install.php =================================================================== RCS file: /cvsroot/mxbb/core/install/mx_install.php,v retrieving revision 1.42 retrieving revision 1.43 diff -C2 -d -r1.42 -r1.43 *** mx_install.php 13 Apr 2005 21:23:26 -0000 1.42 --- mx_install.php 16 Apr 2005 22:28:30 -0000 1.43 *************** *** 54,59 **** // This is shown in the top right corner of the installation panels. // ! define('INSTALLER_VERSION', '1.0.9'); ! define('INSTALLER_NAME', 'mxBB-Installer'); // --- 54,59 ---- // This is shown in the top right corner of the installation panels. // ! define('INSTALLER_VERSION', '1.0.10'); ! define('INSTALLER_NAME', 'mxBB-IWizard'); // *************** *** 863,866 **** --- 863,867 ---- $phpbb_url = get_phpbb_url($phpbb_info['table_prefix']); $db->sql_close(); + $db = false; if( empty($phpbb_url) ) { |
|
From: Markus P. <mar...@us...> - 2005-04-16 22:24:26
|
Update of /cvsroot/mxbb/core/cache In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv2938 Added Files: .htaccess Log Message: Added a .htaccess file with a nice "deny from all" statement in the cache folder. --- NEW FILE: .htaccess --- deny from all |
|
From: Jon O. <jon...@us...> - 2005-04-16 21:51:45
|
Update of /cvsroot/mxbb/core In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv16419 Modified Files: index.php Log Message: weird conflict...did you edit these lately...i see no diff?? Index: index.php =================================================================== RCS file: /cvsroot/mxbb/core/index.php,v retrieving revision 1.30 retrieving revision 1.31 diff -C2 -d -r1.30 -r1.31 *** index.php 13 Apr 2005 20:15:56 -0000 1.30 --- index.php 16 Apr 2005 21:51:35 -0000 1.31 *************** *** 24,27 **** --- 24,28 ---- //define('MX_DEBUG', 1); define( 'IN_PORTAL', 1 ); + $mx_root_path = "./"; *************** *** 36,42 **** --- 37,46 ---- // Start session management + $userdata = session_pagestart($user_ip, - ( 1000 + $page_id )); mx_init_userprefs($userdata); + // End session management + if ( $mx_request_vars->is_request('mx_copy') ) { *************** *** 59,62 **** --- 63,68 ---- } + // Now use the session data + $page_row = $HTTP_SESSION_VARS['mx_pages']['page_' . $page_id]['page_info']; *************** *** 83,86 **** --- 89,95 ---- mx_redirect(append_sid($mx_root_path . "login.$phpEx?redirect=" . mx_this_url(), true)); } + + // Output header + include($mx_root_path . 'includes/page_header.' . $phpEx); *************** *** 323,327 **** } // for ... column ! // Output page $layouttemplate->pparse('mx_main_layout'); --- 332,336 ---- } // for ... column ! // Output page $layouttemplate->pparse('mx_main_layout'); |
|
From: Jon O. <jon...@us...> - 2005-04-16 21:51:44
|
Update of /cvsroot/mxbb/core/includes In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv16419/includes Modified Files: mx_functions.php Log Message: weird conflict...did you edit these lately...i see no diff?? Index: mx_functions.php =================================================================== RCS file: /cvsroot/mxbb/core/includes/mx_functions.php,v retrieving revision 1.35 retrieving revision 1.36 diff -C2 -d -r1.35 -r1.36 *** mx_functions.php 13 Apr 2005 21:23:25 -0000 1.35 --- mx_functions.php 16 Apr 2005 21:51:35 -0000 1.36 *************** *** 257,261 **** WHERE blk.function_id = fnc.function_id AND mdl.module_id = fnc.module_id ! AND fnc.function_file = 'mx_dynamic.php' ORDER BY mdl.module_name ASC, fnc.function_name ASC"; } --- 257,261 ---- WHERE blk.function_id = fnc.function_id AND mdl.module_id = fnc.module_id ! AND fnc.function_file = 'mx_dynamic.php' ORDER BY mdl.module_name ASC, fnc.function_name ASC"; } *************** *** 273,277 **** WHERE blk.function_id = fnc.function_id AND mdl.module_id = fnc.module_id ! AND fnc.function_file = '$function_file' ORDER BY mdl.module_name ASC, fnc.function_name ASC"; } --- 273,277 ---- WHERE blk.function_id = fnc.function_id AND mdl.module_id = fnc.module_id ! AND fnc.function_file = '$function_file' ORDER BY mdl.module_name ASC, fnc.function_name ASC"; } |