|
From: Jon O. <jon...@us...> - 2008-02-08 23:37:32
|
Update of /cvsroot/mxbb/mx_blogs In directory sc8-pr-cvs16.sourceforge.net:/tmp/cvs-serv11401 Modified Files: db_install.php db_uninstall.php trackback.php weblog.php weblog_allentries.php weblog_blocked.php weblog_config.php weblog_contributors.php weblog_entry.php weblog_friends.php weblogs.php Log Message: Removing trailing newlines... Index: weblog_friends.php =================================================================== RCS file: /cvsroot/mxbb/mx_blogs/weblog_friends.php,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** weblog_friends.php 7 Jun 2007 22:01:32 -0000 1.1 --- weblog_friends.php 8 Feb 2008 23:37:23 -0000 1.2 *************** *** 26,30 **** $module_root_path = './'; //include($mx_root_path . 'extension.inc'); ! $phpEx = substr(strrchr(__FILE__, '.'), 1); include($mx_root_path . 'common.'.$phpEx); include_once($phpbb_root_path . 'includes/bbcode.'.$phpEx); --- 26,30 ---- $module_root_path = './'; //include($mx_root_path . 'extension.inc'); ! $phpEx = substr(strrchr(__FILE__, '.'), 1); include($mx_root_path . 'common.'.$phpEx); include_once($phpbb_root_path . 'includes/bbcode.'.$phpEx); *************** *** 42,46 **** ! // // Start initial var setup // --- 42,46 ---- ! // // Start initial var setup // *************** *** 243,247 **** // Get this user's friends data // ! $sql = "SELECT f.friend_id, u.*, w.* FROM " . WEBLOG_FRIENDS_TABLE . " f, " . USERS_TABLE . " u, " . WEBLOGS_TABLE . " w WHERE f.owner_id = $user_id --- 243,247 ---- // Get this user's friends data // ! $sql = "SELECT f.friend_id, u.*, w.* FROM " . WEBLOG_FRIENDS_TABLE . " f, " . USERS_TABLE . " u, " . WEBLOGS_TABLE . " w WHERE f.owner_id = $user_id *************** *** 310,314 **** // $friend_entry_data['entry_text'] = htmlspecialchars($friend_entry_data['entry_text']); ! // BBCode if ( $friend_entry_data['enable_bbcode'] ) --- 310,314 ---- // $friend_entry_data['entry_text'] = htmlspecialchars($friend_entry_data['entry_text']); ! // BBCode if ( $friend_entry_data['enable_bbcode'] ) *************** *** 316,320 **** $friend_entry_data['entry_text'] = bbencode_second_pass($friend_entry_data['entry_text'], $friend_entry_data['bbcode_uid']); } ! // Smilies if ( $friend_entry_data['enable_smilies'] ) --- 316,320 ---- $friend_entry_data['entry_text'] = bbencode_second_pass($friend_entry_data['entry_text'], $friend_entry_data['bbcode_uid']); } ! // Smilies if ( $friend_entry_data['enable_smilies'] ) *************** *** 322,328 **** $friend_entry_data['entry_text'] = smilies_pass($friend_entry_data['entry_text']); } ! $friend_entry_data['entry_text'] = make_clickable($friend_entry_data['entry_text']); ! if ( !$weblog_config['censor_weblog'] ) { --- 322,328 ---- $friend_entry_data['entry_text'] = smilies_pass($friend_entry_data['entry_text']); } ! $friend_entry_data['entry_text'] = make_clickable($friend_entry_data['entry_text']); ! if ( !$weblog_config['censor_weblog'] ) { *************** *** 331,335 **** $replacement_word = array(); obtain_word_list($orig_word, $replacement_word); ! // Censor text and title if (count($orig_word)) --- 331,335 ---- $replacement_word = array(); obtain_word_list($orig_word, $replacement_word); ! // Censor text and title if (count($orig_word)) *************** *** 347,351 **** if ( $mood >= 0 ) ! { $mood = '<strong>[</strong> ' . sprintf($lang['Mood:'], '<img src="modules/mx_blogs/images/weblogs/' . $mood['mood_url'] . '" alt="' . $mood['mood_text'] . '" style="vertical-align: middle" border="0" />', $mood['mood_text']) . ' <strong>]</strong>'; } --- 347,351 ---- if ( $mood >= 0 ) ! { $mood = '<strong>[</strong> ' . sprintf($lang['Mood:'], '<img src="modules/mx_blogs/images/weblogs/' . $mood['mood_url'] . '" alt="' . $mood['mood_text'] . '" style="vertical-align: middle" border="0" />', $mood['mood_text']) . ' <strong>]</strong>'; } *************** *** 371,375 **** $action = ''; } ! $time = create_date($board_config['default_dateformat'], $friend_entry_data['entry_time'], $board_config['board_timezone']); --- 371,375 ---- $action = ''; } ! $time = create_date($board_config['default_dateformat'], $friend_entry_data['entry_time'], $board_config['board_timezone']); *************** *** 457,461 **** mx_message_die(GENERAL_ERROR, "Couldn't get friend of information.", "", __LINE__, __FILE__, $sql); } ! while ( $row = $db->sql_fetchrow($result) ) { --- 457,461 ---- mx_message_die(GENERAL_ERROR, "Couldn't get friend of information.", "", __LINE__, __FILE__, $sql); } ! while ( $row = $db->sql_fetchrow($result) ) { *************** *** 476,480 **** mx_message_die(GENERAL_ERROR, "Couldn't get friend of information.", "", __LINE__, __FILE__, $sql); } ! while ( $row = $db->sql_fetchrow($result) ) { --- 476,480 ---- mx_message_die(GENERAL_ERROR, "Couldn't get friend of information.", "", __LINE__, __FILE__, $sql); } ! while ( $row = $db->sql_fetchrow($result) ) { *************** *** 525,527 **** use_weblog_footer ($weblog_data, $template_dir); ! ?> --- 525,527 ---- use_weblog_footer ($weblog_data, $template_dir); ! ?> \ No newline at end of file Index: weblog_contributors.php =================================================================== RCS file: /cvsroot/mxbb/mx_blogs/weblog_contributors.php,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** weblog_contributors.php 20 Jun 2007 13:43:30 -0000 1.2 --- weblog_contributors.php 8 Feb 2008 23:37:22 -0000 1.3 *************** *** 29,33 **** //include($phpbb_root_path . 'includes/weblogs_common.'.$phpEx); //include($mx_root_path . 'extension.inc'); ! $phpEx = substr(strrchr(__FILE__, '.'), 1); include($mx_root_path . 'common.'.$phpEx); --- 29,33 ---- //include($phpbb_root_path . 'includes/weblogs_common.'.$phpEx); //include($mx_root_path . 'extension.inc'); ! $phpEx = substr(strrchr(__FILE__, '.'), 1); include($mx_root_path . 'common.'.$phpEx); *************** *** 45,49 **** ! // // Start initial var setup // --- 45,49 ---- ! // // Start initial var setup // *************** *** 267,271 **** mx_message_die(GENERAL_ERROR, "Couldn't get contributors information.", "", __LINE__, __FILE__, $sql); } ! while ( $row = $db->sql_fetchrow($result) ) { --- 267,271 ---- mx_message_die(GENERAL_ERROR, "Couldn't get contributors information.", "", __LINE__, __FILE__, $sql); } ! while ( $row = $db->sql_fetchrow($result) ) { *************** *** 309,311 **** use_weblog_footer ( $weblog_data, $template_dir); ! ?> --- 309,311 ---- use_weblog_footer ( $weblog_data, $template_dir); ! ?> \ No newline at end of file Index: db_uninstall.php =================================================================== RCS file: /cvsroot/mxbb/mx_blogs/db_uninstall.php,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** db_uninstall.php 7 Jun 2007 22:01:31 -0000 1.1 --- db_uninstall.php 8 Feb 2008 23:37:21 -0000 1.2 *************** *** 20,24 **** include($mx_root_path . 'extension.inc'); include($mx_root_path . 'common.'.$phpEx); ! // // Start session management --- 20,24 ---- include($mx_root_path . 'extension.inc'); include($mx_root_path . 'common.'.$phpEx); ! // // Start session management *************** *** 26,43 **** $userdata = session_pagestart($user_ip, PAGE_INDEX); mx_init_userprefs($userdata); - - if( !$userdata['session_logged_in'] ) - { - die("Hacking attempt(3)"); - } ! if( $userdata['user_level'] != ADMIN ) ! { ! die("Hacking attempt(4)"); } // // End session management // ! } --- 26,43 ---- $userdata = session_pagestart($user_ip, PAGE_INDEX); mx_init_userprefs($userdata); ! if( !$userdata['session_logged_in'] ) ! { ! die("Hacking attempt(3)"); ! } ! ! if( $userdata['user_level'] != ADMIN ) ! { ! die("Hacking attempt(4)"); } // // End session management // ! } *************** *** 86,88 **** echo "</table><br />"; ! ?> --- 86,88 ---- echo "</table><br />"; ! ?> \ No newline at end of file Index: weblog_entry.php =================================================================== RCS file: /cvsroot/mxbb/mx_blogs/weblog_entry.php,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** weblog_entry.php 31 Jan 2008 03:36:34 -0000 1.2 --- weblog_entry.php 8 Feb 2008 23:37:22 -0000 1.3 *************** *** 24,28 **** $mx_root_path = '../../'; $module_root_path = './'; ! $phpEx = substr(strrchr(__FILE__, '.'), 1); include($mx_root_path . 'common.'.$phpEx); --- 24,28 ---- $mx_root_path = '../../'; $module_root_path = './'; ! $phpEx = substr(strrchr(__FILE__, '.'), 1); include($mx_root_path . 'common.'.$phpEx); *************** *** 381,386 **** { include_once($phpbb_root_path . 'includes/bbcode.' .$phpEx); ! } ! $message = ( $board_config['allow_bbcode'] ) ? bbencode_second_pass($message, $entry_data['bbcode_uid']) : preg_replace('/\:[0-9a-z\:]+\]/si', ']', $entry_data['entry_text']); --- 381,386 ---- { include_once($phpbb_root_path . 'includes/bbcode.' .$phpEx); ! } ! $message = ( $board_config['allow_bbcode'] ) ? bbencode_second_pass($message, $entry_data['bbcode_uid']) : preg_replace('/\:[0-9a-z\:]+\]/si', ']', $entry_data['entry_text']); *************** *** 431,435 **** if ( $mood >= 0 ) ! { $mood = '<strong>[</strong> ' . sprintf($lang['Mood:'], '<img src="' . $mx_root_path . 'modules/mx_blogs/images/weblogs/' . $mood['mood_url'] . '" alt="' . $mood_data['mood_text'] . '" style="vertical-align: middle" border="0" />', $mood['mood_text']) . ' <strong>]</strong>'; } --- 431,435 ---- if ( $mood >= 0 ) ! { $mood = '<strong>[</strong> ' . sprintf($lang['Mood:'], '<img src="' . $mx_root_path . 'modules/mx_blogs/images/weblogs/' . $mood['mood_url'] . '" alt="' . $mood_data['mood_text'] . '" style="vertical-align: middle" border="0" />', $mood['mood_text']) . ' <strong>]</strong>'; } *************** *** 859,868 **** { $post_subject = preg_replace($orig_word, $replacement_word, $post_subject); ! if ($user_sig != '') { $user_sig = str_replace('\"', '"', substr(preg_replace('#(\>(((?>([^><]+|(?R)))*)\<))#se', "preg_replace(\$orig_word, \$replacement_word, '\\0')", '>' . $user_sig . '<'), 1, -1)); } ! $message = str_replace('\"', '"', substr(preg_replace('#(\>(((?>([^><]+|(?R)))*)\<))#se', "preg_replace(\$orig_word, \$replacement_word, '\\0')", '>' . $message . '<'), 1, -1)); } --- 859,868 ---- { $post_subject = preg_replace($orig_word, $replacement_word, $post_subject); ! if ($user_sig != '') { $user_sig = str_replace('\"', '"', substr(preg_replace('#(\>(((?>([^><]+|(?R)))*)\<))#se', "preg_replace(\$orig_word, \$replacement_word, '\\0')", '>' . $user_sig . '<'), 1, -1)); } ! $message = str_replace('\"', '"', substr(preg_replace('#(\>(((?>([^><]+|(?R)))*)\<))#se', "preg_replace(\$orig_word, \$replacement_word, '\\0')", '>' . $message . '<'), 1, -1)); } *************** *** 1050,1052 **** use_weblog_footer ( $weblog_entry_data, $template_dir ); ! ?> --- 1050,1052 ---- use_weblog_footer ( $weblog_entry_data, $template_dir ); ! ?> \ No newline at end of file Index: weblog_config.php =================================================================== RCS file: /cvsroot/mxbb/mx_blogs/weblog_config.php,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** weblog_config.php 31 Jan 2008 03:36:34 -0000 1.3 --- weblog_config.php 8 Feb 2008 23:37:22 -0000 1.4 *************** *** 24,28 **** // //error_reporting( E_ALL ); ! @ini_set( 'display_errors', '1' ); if( !defined('IN_PORTAL') || !is_object($mx_block)) --- 24,28 ---- // //error_reporting( E_ALL ); ! @ini_set( 'display_errors', '1' ); if( !defined('IN_PORTAL') || !is_object($mx_block)) *************** *** 141,145 **** mx_message_die(GENERAL_ERROR, "Couldn't get weblog template information.", "", __LINE__, __FILE__, $sql); } ! if ( !($row = $db->sql_fetchrow($result)) ) { --- 141,145 ---- mx_message_die(GENERAL_ERROR, "Couldn't get weblog template information.", "", __LINE__, __FILE__, $sql); } ! if ( !($row = $db->sql_fetchrow($result)) ) { *************** *** 206,210 **** $show_weblog_info = ( isset($HTTP_POST_VARS['show_weblog_info']) ) ? intval($HTTP_POST_VARS['show_weblog_info']) : 1; $show_shoutbox = ( isset($HTTP_POST_VARS['show_shoutbox']) ) ? intval($HTTP_POST_VARS['show_shoutbox']) : 1; ! $show_categorybox = ( isset($HTTP_POST_VARS['show_categorybox']) ) ? intval($HTTP_POST_VARS['show_categorybox']) : 1; $reply_in_popup = ( isset($HTTP_POST_VARS['reply_in_popup']) ) ? intval($HTTP_POST_VARS['reply_in_popup']) : 1; $shoutbox_desc = ( isset($HTTP_POST_VARS['shoutbox_desc']) ) ? intval($HTTP_POST_VARS['shoutbox_desc']) : 1; --- 206,210 ---- $show_weblog_info = ( isset($HTTP_POST_VARS['show_weblog_info']) ) ? intval($HTTP_POST_VARS['show_weblog_info']) : 1; $show_shoutbox = ( isset($HTTP_POST_VARS['show_shoutbox']) ) ? intval($HTTP_POST_VARS['show_shoutbox']) : 1; ! $show_categorybox = ( isset($HTTP_POST_VARS['show_categorybox']) ) ? intval($HTTP_POST_VARS['show_categorybox']) : 1; $reply_in_popup = ( isset($HTTP_POST_VARS['reply_in_popup']) ) ? intval($HTTP_POST_VARS['reply_in_popup']) : 1; $shoutbox_desc = ( isset($HTTP_POST_VARS['shoutbox_desc']) ) ? intval($HTTP_POST_VARS['shoutbox_desc']) : 1; *************** *** 623,627 **** $sql = "UPDATE " . WEBLOGS_TABLE . " SET template_id = $weblog_template, ! weblog_name = '" . str_replace("\'", "''", $weblog_name) . "', weblog_desc = '" . str_replace("\'", "''", $weblog_desc) . "', weblog_auth = $weblog_auth, --- 623,627 ---- $sql = "UPDATE " . WEBLOGS_TABLE . " SET template_id = $weblog_template, ! weblog_name = '" . str_replace("\'", "''", $weblog_name) . "', weblog_desc = '" . str_replace("\'", "''", $weblog_desc) . "', weblog_auth = $weblog_auth, *************** *** 981,985 **** 'SHOUTBOX_ASC' => ( !$weblog_data['weblog_shoutbox_desc'] ) ? ' checked="checked"' : '', 'PREVIEW_IMG' => $module_root_path . 'weblogs/templates/' . get_template_dir($template_data[0]['template_id']) . '/preview_img.gif', ! 'DELETE_NAME' => ( $weblog_data['deleted'] ) ? 'undelete' : 'delete', 'L_DELETE_WEBLOG' => ( $weblog_data['deleted'] ) ? $lang['Weblog_undelete'] : $lang['Weblog_delete'], --- 981,985 ---- 'SHOUTBOX_ASC' => ( !$weblog_data['weblog_shoutbox_desc'] ) ? ' checked="checked"' : '', 'PREVIEW_IMG' => $module_root_path . 'weblogs/templates/' . get_template_dir($template_data[0]['template_id']) . '/preview_img.gif', ! 'DELETE_NAME' => ( $weblog_data['deleted'] ) ? 'undelete' : 'delete', 'L_DELETE_WEBLOG' => ( $weblog_data['deleted'] ) ? $lang['Weblog_undelete'] : $lang['Weblog_delete'], *************** *** 1006,1008 **** //include($mx_root_path . 'includes/page_tail.'.$phpEx); ! ?> --- 1006,1008 ---- //include($mx_root_path . 'includes/page_tail.'.$phpEx); ! ?> \ No newline at end of file Index: weblog_blocked.php =================================================================== RCS file: /cvsroot/mxbb/mx_blogs/weblog_blocked.php,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** weblog_blocked.php 7 Jun 2007 22:01:32 -0000 1.1 --- weblog_blocked.php 8 Feb 2008 23:37:21 -0000 1.2 *************** *** 29,33 **** //include($phpbb_root_path . 'includes/weblogs_common.'.$phpEx); //include($mx_root_path . 'extension.inc'); ! $phpEx = substr(strrchr(__FILE__, '.'), 1); include($mx_root_path . 'common.'.$phpEx); // --- 29,33 ---- //include($phpbb_root_path . 'includes/weblogs_common.'.$phpEx); //include($mx_root_path . 'extension.inc'); ! $phpEx = substr(strrchr(__FILE__, '.'), 1); include($mx_root_path . 'common.'.$phpEx); // *************** *** 45,49 **** ! // // Start initial var setup // --- 45,49 ---- ! // // Start initial var setup // *************** *** 278,282 **** mx_message_die(GENERAL_ERROR, "Couldn't get blocked user information.", "", __LINE__, __FILE__, $sql); } ! while ( $row = $db->sql_fetchrow($result) ) { --- 278,282 ---- mx_message_die(GENERAL_ERROR, "Couldn't get blocked user information.", "", __LINE__, __FILE__, $sql); } ! while ( $row = $db->sql_fetchrow($result) ) { *************** *** 319,321 **** use_weblog_footer ( $weblog_data, $template_dir); ! ?> --- 319,321 ---- use_weblog_footer ( $weblog_data, $template_dir); ! ?> \ No newline at end of file Index: weblogs.php =================================================================== RCS file: /cvsroot/mxbb/mx_blogs/weblogs.php,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** weblogs.php 31 Jan 2008 03:36:34 -0000 1.4 --- weblogs.php 8 Feb 2008 23:37:23 -0000 1.5 *************** *** 6,10 **** * * File ID : $Id$ ! * Last Modified : $Date$ * ***************************************************************************/ --- 6,10 ---- * * File ID : $Id$ ! * Last Modified : $Date$ * ***************************************************************************/ *************** *** 14,18 **** // //error_reporting( E_ALL ); ! @ini_set( 'display_errors', '1' ); if( !defined('IN_PORTAL') || !is_object($mx_block)) --- 14,18 ---- // //error_reporting( E_ALL ); ! @ini_set( 'display_errors', '1' ); if( !defined('IN_PORTAL') || !is_object($mx_block)) *************** *** 195,199 **** // Viewer of own weblog presumed to have maximum authentication... $sql = "SELECT * FROM " . WEBLOG_ENTRIES_TABLE . " ! WHERE weblog_id = " . $userdata['user_weblog'] . " AND entry_deleted <> " . TRUE . " ORDER BY entry_time DESC LIMIT 1"; --- 195,199 ---- // Viewer of own weblog presumed to have maximum authentication... $sql = "SELECT * FROM " . WEBLOG_ENTRIES_TABLE . " ! WHERE weblog_id = " . $userdata['user_weblog'] . " AND entry_deleted <> " . TRUE . " ORDER BY entry_time DESC LIMIT 1"; *************** *** 211,215 **** if ( $mood >= 0 ) ! { $mood = sprintf($lang['Mood:'], '<img src="modules/mx_blogs/images/weblogs/' . $mood['mood_url'] . '" alt="' . $mood_data['mood_text'] . '" style="vertical-align: middle" border="0" />', $mood['mood_text']); } --- 211,215 ---- if ( $mood >= 0 ) ! { $mood = sprintf($lang['Mood:'], '<img src="modules/mx_blogs/images/weblogs/' . $mood['mood_url'] . '" alt="' . $mood_data['mood_text'] . '" style="vertical-align: middle" border="0" />', $mood['mood_text']); } *************** *** 225,229 **** if ( $currently > 0 ) { ! $action = sprintf($lang['Currently:'], '<img src="modules/mx_blogs/images/weblogs/' . $currently['action_url'] . '" alt="' . $currently['action_text'] . ' ' . $last_entry_data['currently_text'] . '" style="vertical-align: middle" border="0" />', $currently['action_text'] . ' ' . $last_entry_data['currently_text']); } else if ( $last_entry_data['currently_text'] && $currently == -2 ) --- 225,229 ---- if ( $currently > 0 ) { ! $action = sprintf($lang['Currently:'], '<img src="modules/mx_blogs/images/weblogs/' . $currently['action_url'] . '" alt="' . $currently['action_text'] . ' ' . $last_entry_data['currently_text'] . '" style="vertical-align: middle" border="0" />', $currently['action_text'] . ' ' . $last_entry_data['currently_text']); } else if ( $last_entry_data['currently_text'] && $currently == -2 ) *************** *** 535,539 **** if ( $mood >= 0 ) ! { $mood = sprintf($lang['Mood:'], '<img src="modules/mx_blogs/images/weblogs/' . $mood['mood_url'] . '" alt="' . $mood_data['mood_text'] . '" style="vertical-align: middle" border="0" />', $mood['mood_text']); } --- 535,539 ---- if ( $mood >= 0 ) ! { $mood = sprintf($lang['Mood:'], '<img src="modules/mx_blogs/images/weblogs/' . $mood['mood_url'] . '" alt="' . $mood_data['mood_text'] . '" style="vertical-align: middle" border="0" />', $mood['mood_text']); } *************** *** 549,553 **** if ( $currently > 0 ) { ! $action = sprintf($lang['Currently:'], '<img src="modules/mx_blogs/images/weblogs/' . $currently['action_url'] . '" alt="' . $currently['action_text'] . ' ' . $last_entry_data['currently_text'] . '" style="vertical-align: middle" border="0" />', $currently['action_text'] . ' ' . $last_entry_data['currently_text']); } else if ( $last_entry_data['currently_text'] && $currently == -2 ) --- 549,553 ---- if ( $currently > 0 ) { ! $action = sprintf($lang['Currently:'], '<img src="modules/mx_blogs/images/weblogs/' . $currently['action_url'] . '" alt="' . $currently['action_text'] . ' ' . $last_entry_data['currently_text'] . '" style="vertical-align: middle" border="0" />', $currently['action_text'] . ' ' . $last_entry_data['currently_text']); } else if ( $last_entry_data['currently_text'] && $currently == -2 ) *************** *** 667,669 **** $template->pparse('bottom'); ! ?> --- 667,669 ---- $template->pparse('bottom'); ! ?> \ No newline at end of file Index: weblog.php =================================================================== RCS file: /cvsroot/mxbb/mx_blogs/weblog.php,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** weblog.php 31 Jan 2008 03:36:34 -0000 1.3 --- weblog.php 8 Feb 2008 23:37:21 -0000 1.4 *************** *** 32,36 **** { //include($mx_root_path . 'extension.inc'); ! $phpEx = substr(strrchr(__FILE__, '.'), 1); include($mx_root_path . 'common.'.$phpEx); } --- 32,36 ---- { //include($mx_root_path . 'extension.inc'); ! $phpEx = substr(strrchr(__FILE__, '.'), 1); include($mx_root_path . 'common.'.$phpEx); } *************** *** 130,134 **** $blocked_data[] = $row; } ! // // Start initial var setup // --- 130,134 ---- $blocked_data[] = $row; } ! // // Start initial var setup // *************** *** 560,568 **** if ( $weblog_config['birthday_mod'] == 1 ) { ! $this_year = create_date('Y', time(), $board_config['board_timezone']); $this_date = create_date('md', time(), $board_config['board_timezone']); ! if ( $weblog_ownerdata['user_birthday'] != 999999 ) ! { $poster_birthdate = realdate('md', $weblog_ownerdata['user_birthday']); if ( $weblog_config['birthday_zodiac_mod'] == 1 ) --- 560,568 ---- if ( $weblog_config['birthday_mod'] == 1 ) { ! $this_year = create_date('Y', time(), $board_config['board_timezone']); $this_date = create_date('md', time(), $board_config['board_timezone']); ! if ( $weblog_ownerdata['user_birthday'] != 999999 ) ! { $poster_birthdate = realdate('md', $weblog_ownerdata['user_birthday']); if ( $weblog_config['birthday_zodiac_mod'] == 1 ) *************** *** 747,751 **** if ( $mood >= 0 ) ! { $mood = '<strong>[</strong> ' . sprintf($lang['Mood:'], '<img src="images/weblogs/' . $mood['mood_url'] . '" alt="' . $mood_data['mood_text'] . '" style="vertical-align: middle" border="0" />', $mood['mood_text']) . ' <strong>]</strong>'; } --- 747,751 ---- if ( $mood >= 0 ) ! { $mood = '<strong>[</strong> ' . sprintf($lang['Mood:'], '<img src="images/weblogs/' . $mood['mood_url'] . '" alt="' . $mood_data['mood_text'] . '" style="vertical-align: middle" border="0" />', $mood['mood_text']) . ' <strong>]</strong>'; } *************** *** 761,765 **** if ( $currently > 0 ) { ! $action = '<strong>[</strong> ' . sprintf($lang['Currently:'], '<img src="images/weblogs/' . $currently['action_url'] . '" alt="' . $currently['action_text'] . ' ' . $entry_data[$i]['currently_text'] . '" style="vertical-align: middle" border="0" />', $currently['action_text'] . ' ' . $entry_data[$i]['currently_text']) . ' <strong>]</strong>'; } else if ( $entry_data[$i]['currently_text'] && $currently == -2 ) --- 761,765 ---- if ( $currently > 0 ) { ! $action = '<strong>[</strong> ' . sprintf($lang['Currently:'], '<img src="images/weblogs/' . $currently['action_url'] . '" alt="' . $currently['action_text'] . ' ' . $entry_data[$i]['currently_text'] . '" style="vertical-align: middle" border="0" />', $currently['action_text'] . ' ' . $entry_data[$i]['currently_text']) . ' <strong>]</strong>'; } else if ( $entry_data[$i]['currently_text'] && $currently == -2 ) *************** *** 771,775 **** $action = ''; } ! --- 771,775 ---- $action = ''; } ! *************** *** 785,789 **** ! $time = create_date($board_config['default_dateformat'], $entry_data[$i]['entry_time'], $board_config['board_timezone']); --- 785,789 ---- ! $time = create_date($board_config['default_dateformat'], $entry_data[$i]['entry_time'], $board_config['board_timezone']); *************** *** 828,832 **** $month = create_date("m", time(), $board_config['board_timezone']); } ! if ( !$year ) { --- 828,832 ---- $month = create_date("m", time(), $board_config['board_timezone']); } ! if ( !$year ) { *************** *** 938,945 **** for ( $i = 0; $i < count($category_data); $i++ ) { ! $template->assign_block_vars('switch_categorybox.categoryrow', array( 'CATEGORY' => $category_data[$i]) ); ! $template->assign_block_vars('categoryrow', array( 'CATEGORY' => $category_data[$i]) --- 938,945 ---- for ( $i = 0; $i < count($category_data); $i++ ) { ! $template->assign_block_vars('switch_categorybox.categoryrow', array( 'CATEGORY' => $category_data[$i]) ); ! $template->assign_block_vars('categoryrow', array( 'CATEGORY' => $category_data[$i]) *************** *** 1057,1063 **** // $message = str_replace("\n", "\n<br />\n", $message); ! $row_class = ( $i % 2 ) ? ' class="row2"' : ' class="row1"'; ! $template->assign_block_vars('switch_shoutbox.shoutrow', array( 'DELETE_SHOUT' => ( $weblog_data['weblog_id'] == $userdata['user_weblog'] ) ? '<div style="float: right; font-weight: bold">[ <a href="' . append_sid("weblog.$phpEx?" . POST_WEBLOG_URL . "=" . $weblog_data['weblog_id'] . "&d=" . $shout_data[$i]['shout_id']) . '">X</a> ]</div>' : '', --- 1057,1063 ---- // $message = str_replace("\n", "\n<br />\n", $message); ! $row_class = ( $i % 2 ) ? ' class="row2"' : ' class="row1"'; ! $template->assign_block_vars('switch_shoutbox.shoutrow', array( 'DELETE_SHOUT' => ( $weblog_data['weblog_id'] == $userdata['user_weblog'] ) ? '<div style="float: right; font-weight: bold">[ <a href="' . append_sid("weblog.$phpEx?" . POST_WEBLOG_URL . "=" . $weblog_data['weblog_id'] . "&d=" . $shout_data[$i]['shout_id']) . '">X</a> ]</div>' : '', *************** *** 1134,1140 **** 'L_CONTRIBUTORS' => $lang['Contributors'], 'L_EDIT_CONTRIBUTORS' => $lang['Edit_contributors'], ! 'L_DISABLE_HTML' => $lang['Disable_HTML_post'], ! 'L_DISABLE_BBCODE' => $lang['Disable_BBCode_post'], ! 'L_DISABLE_SMILIES' => $lang['Disable_Smilies_post'], 'L_NO_SHOUTS' => $lang['No_shouts'], 'L_NO_CATEGORY' => $lang['No_category'], --- 1134,1140 ---- 'L_CONTRIBUTORS' => $lang['Contributors'], 'L_EDIT_CONTRIBUTORS' => $lang['Edit_contributors'], ! 'L_DISABLE_HTML' => $lang['Disable_HTML_post'], ! 'L_DISABLE_BBCODE' => $lang['Disable_BBCode_post'], ! 'L_DISABLE_SMILIES' => $lang['Disable_Smilies_post'], 'L_NO_SHOUTS' => $lang['No_shouts'], 'L_NO_CATEGORY' => $lang['No_category'], *************** *** 1231,1247 **** if ( $weblog_config['gender_mod'] == 1 ) { ! if ( !empty($weblog_ownerdata['user_gender'])) ! { ! switch ($weblog_ownerdata['user_gender']) ! { case 1: $gender = $lang['Male']; ! break; case 2: $gender = $lang['Female']; ! break; default: $gender = $lang['No_gender_specify']; ! } } else --- 1231,1247 ---- if ( $weblog_config['gender_mod'] == 1 ) { ! if ( !empty($weblog_ownerdata['user_gender'])) ! { ! switch ($weblog_ownerdata['user_gender']) ! { case 1: $gender = $lang['Male']; ! break; case 2: $gender = $lang['Female']; ! break; default: $gender = $lang['No_gender_specify']; ! } } else *************** *** 1361,1365 **** 'S_CUSTOM_BLOCK' => ( $weblog_data['custom_block_title'] && $weblog_data['custom_block'] ) ? $weblog_data['custom_block'] : '') ); ! if ( !$weblog_data['weblog_advanced'] ) { --- 1361,1365 ---- 'S_CUSTOM_BLOCK' => ( $weblog_data['custom_block_title'] && $weblog_data['custom_block'] ) ? $weblog_data['custom_block'] : '') ); ! if ( !$weblog_data['weblog_advanced'] ) { *************** *** 1375,1377 **** use_weblog_footer ( $weblog_data, $template_dir, FALSE ); ! ?> --- 1375,1377 ---- use_weblog_footer ( $weblog_data, $template_dir, FALSE ); ! ?> \ No newline at end of file Index: db_install.php =================================================================== RCS file: /cvsroot/mxbb/mx_blogs/db_install.php,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** db_install.php 20 Jun 2007 13:19:57 -0000 1.2 --- db_install.php 8 Feb 2008 23:37:20 -0000 1.3 *************** *** 26,30 **** include($mx_root_path . 'extension.inc'); include($mx_root_path . 'common.'.$phpEx); ! // // Start session management --- 26,30 ---- include($mx_root_path . 'extension.inc'); include($mx_root_path . 'common.'.$phpEx); ! // // Start session management *************** *** 32,49 **** $userdata = session_pagestart($user_ip, PAGE_INDEX); mx_init_userprefs($userdata); - - if( !$userdata['session_logged_in'] ) - { - die("Hacking attempt(3)"); - } ! if( $userdata['user_level'] != ADMIN ) ! { ! die("Hacking attempt(4)"); } // // End session management // ! } --- 32,49 ---- $userdata = session_pagestart($user_ip, PAGE_INDEX); mx_init_userprefs($userdata); ! if( !$userdata['session_logged_in'] ) ! { ! die("Hacking attempt(3)"); ! } ! ! if( $userdata['user_level'] != ADMIN ) ! { ! die("Hacking attempt(4)"); } // // End session management // ! } *************** *** 328,330 **** ! ?> --- 328,330 ---- ! ?> \ No newline at end of file Index: weblog_allentries.php =================================================================== RCS file: /cvsroot/mxbb/mx_blogs/weblog_allentries.php,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** weblog_allentries.php 31 Jan 2008 03:36:34 -0000 1.2 --- weblog_allentries.php 8 Feb 2008 23:37:21 -0000 1.3 *************** *** 28,32 **** //include($phpbb_root_path . 'common.'.$phpEx); //include($mx_root_path . 'extension.inc'); ! $phpEx = substr(strrchr(__FILE__, '.'), 1); include($mx_root_path . 'common.'.$phpEx); // --- 28,32 ---- //include($phpbb_root_path . 'common.'.$phpEx); //include($mx_root_path . 'extension.inc'); ! $phpEx = substr(strrchr(__FILE__, '.'), 1); include($mx_root_path . 'common.'.$phpEx); // *************** *** 152,160 **** $min_entry_time = time() - ($entry_days * 86400); ! $sql = "SELECT COUNT(e.entry_id) AS weblog_entries FROM " . WEBLOG_ENTRIES_TABLE . " e, " . WEBLOG_REPLIES_TABLE . " r ! WHERE e.weblog_id = $weblog_id AND r.reply_id = e.entry_last_post_id ! AND r.post_time >= $min_entry_time"; if( !$result = $db->sql_query($sql) ) --- 152,160 ---- $min_entry_time = time() - ($entry_days * 86400); ! $sql = "SELECT COUNT(e.entry_id) AS weblog_entries FROM " . WEBLOG_ENTRIES_TABLE . " e, " . WEBLOG_REPLIES_TABLE . " r ! WHERE e.weblog_id = $weblog_id AND r.reply_id = e.entry_last_post_id ! AND r.post_time >= $min_entry_time"; if( !$result = $db->sql_query($sql) ) *************** *** 202,206 **** mx_message_die(GENERAL_ERROR, "Couldn't get template directory information.", "", __LINE__, __FILE__, $sql); } ! if ( $row = $db->sql_fetchrow($result) ) { --- 202,206 ---- mx_message_die(GENERAL_ERROR, "Couldn't get template directory information.", "", __LINE__, __FILE__, $sql); } ! if ( $row = $db->sql_fetchrow($result) ) { *************** *** 345,349 **** if ( $mood >= 0 ) ! { $mood = '<img src="images/weblogs/' . $mood['mood_url'] . '" alt="' . $mood_data['mood_text'] . '" border="0" />'; } --- 345,349 ---- if ( $mood >= 0 ) ! { $mood = '<img src="images/weblogs/' . $mood['mood_url'] . '" alt="' . $mood_data['mood_text'] . '" border="0" />'; } *************** *** 359,363 **** if ( $currently > 0 ) { ! $action = '<img src="images/weblogs/' . $currently['action_url'] . '" alt="' . $currently['action_text'] . ' ' . $entry_data[$i]['currently_text'] . '" border="0" />'; } else --- 359,363 ---- if ( $currently > 0 ) { ! $action = '<img src="images/weblogs/' . $currently['action_url'] . '" alt="' . $currently['action_text'] . ' ' . $entry_data[$i]['currently_text'] . '" border="0" />'; } else *************** *** 402,406 **** if( $userdata['session_logged_in'] ) { ! if( $entry_data[$i]['entry_time'] > $userdata['user_lastvisit'] ) { if( !empty($tracking_entries) || !empty($tracking_weblogs) || isset($HTTP_COOKIE_VARS[$board_config['cookie_name'] . '_f_all']) ) --- 402,406 ---- if( $userdata['session_logged_in'] ) { ! if( $entry_data[$i]['entry_time'] > $userdata['user_lastvisit'] ) { if( !empty($tracking_entries) || !empty($tracking_weblogs) || isset($HTTP_COOKIE_VARS[$board_config['cookie_name'] . '_f_all']) ) *************** *** 455,459 **** } } ! else { $entry_image = $entry; --- 455,459 ---- } } ! else { $entry_image = $entry; *************** *** 477,481 **** $last_post_author = ( $entry_data[$i]['poster_id'] == ANONYMOUS ) ? ( ($entry_data[$i]['post_username'] != '' ) ? $entry_data[$i]['post_username'] . ' ' : $lang['Guest'] . ' ' ) : '<a href="' . append_sid("profile.$phpEx?mode=viewprofile&" . POST_USERS_URL . '=' . $entry_data[$i]['user_id']) . '">' . $entry_data[$i]['username'] . '</a>'; ! if( !$entry_data[$i]['entry_last_post_id'] ) { --- 477,481 ---- $last_post_author = ( $entry_data[$i]['poster_id'] == ANONYMOUS ) ? ( ($entry_data[$i]['post_username'] != '' ) ? $entry_data[$i]['post_username'] . ' ' : $lang['Guest'] . ' ' ) : '<a href="' . append_sid("profile.$phpEx?mode=viewprofile&" . POST_USERS_URL . '=' . $entry_data[$i]['user_id']) . '">' . $entry_data[$i]['username'] . '</a>'; ! if( !$entry_data[$i]['entry_last_post_id'] ) { *************** *** 520,524 **** $goto_page = ''; } ! $view_entry_url = append_sid($mx_root_path . "modules/mx_blogs/weblog_entry.$phpEx?" . POST_ENTRY_URL . "=$entry_id"); --- 520,524 ---- $goto_page = ''; } ! $view_entry_url = append_sid($mx_root_path . "modules/mx_blogs/weblog_entry.$phpEx?" . POST_ENTRY_URL . "=$entry_id"); *************** *** 543,549 **** 'VIEWS' => $views, ! 'LAST_POST_TIME' => $last_post_time, ! 'LAST_POST_AUTHOR' => $last_post_author, ! 'LAST_POST_IMG' => $last_post_url, 'U_VIEW_ENTRY' => $view_entry_url) --- 543,549 ---- 'VIEWS' => $views, ! 'LAST_POST_TIME' => $last_post_time, ! 'LAST_POST_AUTHOR' => $last_post_author, ! 'LAST_POST_IMG' => $last_post_url, 'U_VIEW_ENTRY' => $view_entry_url) *************** *** 553,557 **** $template->assign_vars(array( 'PAGINATION' => generate_pagination($mx_root_path . "weblog.$phpEx?" . POST_WEBLOG_URL . "=$weblog_id&entrydays=$entry_days", count($entry_data), $board_config['topics_per_page'], $start), ! 'PAGE_NUMBER' => sprintf($lang['Page_of'], ( floor( $start / $board_config['topics_per_page'] ) + 1 ), ceil( count($entry_data) / $board_config['topics_per_page'] )), 'L_GOTO_PAGE' => $lang['Goto_page']) --- 553,557 ---- $template->assign_vars(array( 'PAGINATION' => generate_pagination($mx_root_path . "weblog.$phpEx?" . POST_WEBLOG_URL . "=$weblog_id&entrydays=$entry_days", count($entry_data), $board_config['topics_per_page'], $start), ! 'PAGE_NUMBER' => sprintf($lang['Page_of'], ( floor( $start / $board_config['topics_per_page'] ) + 1 ), ceil( count($entry_data) / $board_config['topics_per_page'] )), 'L_GOTO_PAGE' => $lang['Goto_page']) *************** *** 633,635 **** use_weblog_footer ( $weblog_data, $template_dir ); ! ?> --- 633,635 ---- use_weblog_footer ( $weblog_data, $template_dir ); ! ?> \ No newline at end of file Index: trackback.php =================================================================== RCS file: /cvsroot/mxbb/mx_blogs/trackback.php,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** trackback.php 7 Jun 2007 22:01:32 -0000 1.1 --- trackback.php 8 Feb 2008 23:37:21 -0000 1.2 *************** *** 134,136 **** exit; ! ?> --- 134,136 ---- exit; ! ?> \ No newline at end of file |