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: Jon O. <jon...@us...> - 2006-06-29 22:03:26
|
Update of /cvsroot/mxbb/mx_calsnails/includes In directory sc8-pr-cvs7.sourceforge.net:/tmp/cvs-serv27752/modules/mx_calsnails/includes Modified Files: cal_functions.php mx_common.php Log Message: Installation bug adminCP lang keys initialization checks Index: cal_functions.php =================================================================== RCS file: /cvsroot/mxbb/mx_calsnails/includes/cal_functions.php,v retrieving revision 1.6 retrieving revision 1.7 diff -C2 -d -r1.6 -r1.7 *** cal_functions.php 29 Jun 2006 13:39:03 -0000 1.6 --- cal_functions.php 29 Jun 2006 22:03:22 -0000 1.7 *************** *** 802,806 **** $board_config, $cal_config, $id, $day, $month, $year, $userdata, $lang, $event_desc, $subject, $caluser, $block_size, $cal_filter, $block_id, ! $cal_mode_mini, $cal_page_id, $module_root_path, $endday, $endmonth, $endyear, $langdays, $template, $cal_version, $db, $homeurl; --- 802,806 ---- $board_config, $cal_config, $id, $day, $month, $year, $userdata, $lang, $event_desc, $subject, $caluser, $block_size, $cal_filter, $block_id, ! $cal_mode_mini, $cal_page_id, $cal_block_id, $module_root_path, $endday, $endmonth, $endyear, $langdays, $template, $cal_version, $db, $homeurl; *************** *** 862,872 **** if ( $cal_mode_mini ) { ! $template->assign_vars( array( 'S_ACTION' => append_sid( this_mxurl( '', 0, $cal_page_id ) ), ! 'U_CAL_MONTH' => append_sid( this_mxurl( "month=" . $month . "&year=" . $year, 0, $cal_page_id ) ), ! ) ! ); } ! $template->assign_vars( array( 'BLOCK_SIZE' => $block_size, 'PHPBBHEADER' => $phpbbheaders, 'CAL_MONTH' => $lang['datetime'][gmdate( "F", gmmktime( 0, 0, 0, $month, 1, $year ) )], --- 862,877 ---- if ( $cal_mode_mini ) { ! if (intval($cal_block_id) == 0) ! { ! $template->assign_block_vars( 'info', array() ); ! } ! $template->assign_vars( array( ! 'S_ACTION' => append_sid( this_mxurl( '', 0, $cal_page_id ) ), ! 'U_CAL_MONTH' => append_sid( this_mxurl( "month=" . $month . "&year=" . $year, 0, $cal_page_id ) ), ! )); } ! $template->assign_vars( array( ! 'BLOCK_SIZE' => $block_size, 'PHPBBHEADER' => $phpbbheaders, 'CAL_MONTH' => $lang['datetime'][gmdate( "F", gmmktime( 0, 0, 0, $month, 1, $year ) )], Index: mx_common.php =================================================================== RCS file: /cvsroot/mxbb/mx_calsnails/includes/mx_common.php,v retrieving revision 1.16 retrieving revision 1.17 diff -C2 -d -r1.16 -r1.17 *** mx_common.php 29 Jun 2006 13:39:03 -0000 1.16 --- mx_common.php 29 Jun 2006 22:03:22 -0000 1.17 *************** *** 28,32 **** $sql = "SELECT * FROM " . CALLITE_CONFIG_TABLE; ! if ( !( $result = $db->sql_query( $sql, 300 ) ) ) { mx_message_die( GENERAL_ERROR, "Couldn't query calendar config table", "", __LINE__, __FILE__, $sql ); --- 28,32 ---- $sql = "SELECT * FROM " . CALLITE_CONFIG_TABLE; ! if ( !( $result = $db->sql_query( $sql, 100 ) ) ) { mx_message_die( GENERAL_ERROR, "Couldn't query calendar config table", "", __LINE__, __FILE__, $sql ); *************** *** 42,45 **** --- 42,46 ---- $cal_dateformat = !empty( $cal_config['cal_dateformat'] ) ? $cal_config['cal_dateformat'] : $board_config['default_dateformat']; + // Timezone off 1 day fix // $cal_timezone = $board_config['board_timezone']; |
|
From: Jon O. <jon...@us...> - 2006-06-29 22:03:26
|
Update of /cvsroot/mxbb/mx_calsnails In directory sc8-pr-cvs7.sourceforge.net:/tmp/cvs-serv27752/modules/mx_calsnails Modified Files: db_install.php db_upgrade.php mx_calendar_events.php Log Message: Installation bug adminCP lang keys initialization checks Index: mx_calendar_events.php =================================================================== RCS file: /cvsroot/mxbb/mx_calsnails/mx_calendar_events.php,v retrieving revision 1.20 retrieving revision 1.21 diff -C2 -d -r1.20 -r1.21 *** mx_calendar_events.php 29 Jun 2006 13:39:03 -0000 1.20 --- mx_calendar_events.php 29 Jun 2006 22:03:22 -0000 1.21 *************** *** 72,79 **** // $cal_block_id = $mx_block->get_parameters( 'target_block' ); - $cal_page_id = get_page_id( $cal_block_id ); ! $cal_block_config = read_block_config( $cal_block_id ); ! $cal_page_filter = $cal_block_config[$cal_block_id]['cal_filter']['parameter_value'] == 'TRUE'; // --- 72,91 ---- // $cal_block_id = $mx_block->get_parameters( 'target_block' ); ! // ! // Toggles ! // ! if (intval($cal_block_id) > 0) ! { ! $cal_page_id = get_page_id( $cal_block_id ); ! $cal_block_config = read_block_config( $cal_block_id ); ! $cal_page_filter = $cal_block_config[$cal_block_id]['cal_filter']['parameter_value'] == 'TRUE'; ! } ! else ! { ! $cal_page_id = $page_id; ! $cal_page_filter = false; ! $template->assign_block_vars( 'no_events', array( 'NO_EVENTS' => 'This block is not correctly configured. Use the blockCP and define its target calsnails block.' ) ); ! } // Index: db_install.php =================================================================== RCS file: /cvsroot/mxbb/mx_calsnails/db_install.php,v retrieving revision 1.21 retrieving revision 1.22 diff -C2 -d -r1.21 -r1.22 *** db_install.php 29 Jun 2006 13:39:03 -0000 1.21 --- db_install.php 29 Jun 2006 22:03:22 -0000 1.22 *************** *** 61,65 **** bbcode_uid varchar(10), block_id mediumint(8) unsigned NOT NULL default '0', ! PRIMARY KEY (id) )", // Table: Calendar Lite Configuration --- 61,65 ---- bbcode_uid varchar(10), block_id mediumint(8) unsigned NOT NULL default '0', ! PRIMARY KEY (event_id) )", // Table: Calendar Lite Configuration Index: db_upgrade.php =================================================================== RCS file: /cvsroot/mxbb/mx_calsnails/db_upgrade.php,v retrieving revision 1.14 retrieving revision 1.15 diff -C2 -d -r1.14 -r1.15 *** db_upgrade.php 29 Jun 2006 13:39:03 -0000 1.14 --- db_upgrade.php 29 Jun 2006 22:03:22 -0000 1.15 *************** *** 71,157 **** $sql[] = "ALTER TABLE " . CALLITE_EVENTS_TABLE . " ADD block_id mediumint(8) unsigned NOT NULL default '0' "; - /* - // Now add some new parameters for the main LITE block - // First get function_id - $sqltmp = "SELECT function_id FROM " . $mx_table_prefix . "function WHERE function_file = 'calendar.php' LIMIT 1"; - if ( !( $result = $db->sql_query( $sqltmp ) ) ) - { - mx_message_die( CRITICAL_ERROR, "Could not query portal version", "", __LINE__, __FILE__, $sql ); - } - $row = $db->sql_fetchrow( $result ) ; - $function_id = $row['function_id']; - // Then get block_id(s) - $sqltmp2 = "SELECT block_id FROM " . $mx_table_prefix . "block WHERE function_id = '$function_id' LIMIT 1"; - if ( !( $result = $db->sql_query( $sqltmp2 ) ) ) - { - mx_message_die( CRITICAL_ERROR, "Could not query portal version", "", __LINE__, __FILE__, $sql ); - } - - $parameter_id = getMaxId( PARAMETER_TABLE, 'parameter_id' ); - $parameter_id1 = $parameter_id + 1; - $sql[] = "REPLACE INTO " . $mx_table_prefix . "parameter VALUES('" . $parameter_id1 . "', '" . $function_id . "', 'auth_all', 'Function', '1', 'get_list_static(\"{parameter_id}[]\",array(\"No access\",\"View only\",\"View,Suggest\",\"View,Add\",\"View,Add(Edit/Delete own)\"),\"{parameter_value}\")')"; - $parameter_id2 = $parameter_id + 2; - $sql[] = "REPLACE INTO " . $mx_table_prefix . "parameter VALUES('" . $parameter_id2 . "', '" . $function_id . "', 'auth_reg', 'Function', '2', 'get_list_static(\"{parameter_id}[]\",array(\"No access\",\"View only\",\"View,Suggest\",\"View,Add\",\"View,Add(Edit/Delete own)\"),\"{parameter_value}\")')"; - $parameter_id3 = $parameter_id + 3; - $sql[] = "REPLACE INTO " . $mx_table_prefix . "parameter VALUES('" . $parameter_id3 . "', '" . $function_id . "', 'cal_filter', 'Boolean', 'FALSE', '')"; - - while ( $row = $db->sql_fetchrow( $result ) ) - { - $block_id = $row['block_id']; - $sql[] = "REPLACE INTO " . $mx_table_prefix . "block_system_parameter VALUES('" . $block_id . "', '" . $parameter_id1 . "', '1', NULL)"; - $sql[] = "REPLACE INTO " . $mx_table_prefix . "block_system_parameter VALUES('" . $block_id . "', '" . $parameter_id2 . "', '2', NULL)"; - $sql[] = "REPLACE INTO " . $mx_table_prefix . "block_system_parameter VALUES('" . $block_id . "', '" . $parameter_id3 . "', 'FALSE', NULL)"; - } - // Now add some new parameters for the mini calendar - // First get function_id - $sqltmp = "SELECT function_id FROM " . $mx_table_prefix . "function WHERE function_file = 'mx_calendar_mini.php' LIMIT 1"; - if ( !( $result = $db->sql_query( $sqltmp ) ) ) - { - mx_message_die( CRITICAL_ERROR, "Could not query portal version", "", __LINE__, __FILE__, $sql ); - } - $row = $db->sql_fetchrow( $result ) ; - $function_id = $row['function_id']; - // Then get block_id(s) - $sqltmp2 = "SELECT block_id FROM " . $mx_table_prefix . "block WHERE function_id = '$function_id' LIMIT 1"; - if ( !( $result = $db->sql_query( $sqltmp2 ) ) ) - { - mx_message_die( CRITICAL_ERROR, "Could not query portal version", "", __LINE__, __FILE__, $sql ); - } - - $parameter_id = getMaxId( PARAMETER_TABLE, 'parameter_id' ); - $parameter_id1 = $parameter_id + 1; - $sql[] = "REPLACE INTO " . $mx_table_prefix . "parameter VALUES('" . $parameter_id1 . "', '" . $function_id . "', 'target_block', 'Function', '0', 'get_list_formatted(\"calsnails\",\"{parameter_value}\",\"{parameter_id}[]\")')"; - - while ( $row = $db->sql_fetchrow( $result ) ) - { - $block_id = $row['block_id']; - $sql[] = "REPLACE INTO " . $mx_table_prefix . "block_system_parameter VALUES('" . $block_id . "', '" . $parameter_id1 . "', '0', NULL)"; - } - // Now add some new parameters for the EVENTS block - // First get function_id - $sqltmp = "SELECT function_id FROM " . $mx_table_prefix . "function WHERE function_file = 'mx_calendar_events.php' LIMIT 1"; - if ( !( $result = $db->sql_query( $sqltmp ) ) ) - { - mx_message_die( CRITICAL_ERROR, "Could not query portal version", "", __LINE__, __FILE__, $sql ); - } - $row = $db->sql_fetchrow( $result ) ; - $function_id = $row['function_id']; - // Then get block_id(s) - $sqltmp2 = "SELECT block_id FROM " . $mx_table_prefix . "block WHERE function_id = '$function_id' LIMIT 1"; - if ( !( $result = $db->sql_query( $sqltmp2 ) ) ) - { - mx_message_die( CRITICAL_ERROR, "Could not query portal version", "", __LINE__, __FILE__, $sql ); - } - - $parameter_id = getMaxId( PARAMETER_TABLE, 'parameter_id' ); - $parameter_id1 = $parameter_id + 1; - $sql[] = "REPLACE INTO " . $mx_table_prefix . "parameter VALUES('" . $parameter_id1 . "', '" . $function_id . "', 'target_block', 'Function', '0', 'get_list_formatted(\"calsnails\",\"{parameter_value}\",\"{parameter_id}[]\")')"; - - while ( $row = $db->sql_fetchrow( $result ) ) - { - $block_id = $row['block_id']; - $sql[] = "REPLACE INTO " . $mx_table_prefix . "block_system_parameter VALUES('" . $block_id . "', '" . $parameter_id1 . "', '0', NULL)"; - } - */ } --- 71,74 ---- |
|
From: Jon O. <jon...@us...> - 2006-06-29 22:03:26
|
Update of /cvsroot/mxbb/mx_calsnails/admin In directory sc8-pr-cvs7.sourceforge.net:/tmp/cvs-serv27752/modules/mx_calsnails/admin Modified Files: admin_calendar.php Log Message: Installation bug adminCP lang keys initialization checks Index: admin_calendar.php =================================================================== RCS file: /cvsroot/mxbb/mx_calsnails/admin/admin_calendar.php,v retrieving revision 1.13 retrieving revision 1.14 diff -C2 -d -r1.13 -r1.14 *** admin_calendar.php 29 Jun 2006 13:39:02 -0000 1.13 --- admin_calendar.php 29 Jun 2006 22:03:21 -0000 1.14 *************** *** 18,30 **** } ! $mx_root_path = '../../../'; ! $module_root_path = "../"; $phpEx = substr(strrchr(__FILE__, '.'), 1); require( $mx_root_path . '/admin/pagestart.' . $phpEx ); - require( $module_root_path . 'includes/mx_common.' . $phpEx ); - - $caltable = CALLITE_CONFIG_TABLE; include_once( $mx_root_path . 'admin/page_header_admin.' . $phpEx ); $sql = "SELECT * FROM " . $caltable; --- 18,42 ---- } ! $mx_root_path = './../../../'; ! $module_root_path = "./../"; $phpEx = substr(strrchr(__FILE__, '.'), 1); require( $mx_root_path . '/admin/pagestart.' . $phpEx ); include_once( $mx_root_path . 'admin/page_header_admin.' . $phpEx ); + include_once( $module_root_path . 'includes/mx_common.' . $phpEx ); + + // ********************************************************************** + // Read language definition + // ********************************************************************** + if ( !file_exists( $module_root_path . 'language/lang_' . $board_config['default_lang'] . '/lang_admin.' . $phpEx ) ) + { + include( $module_root_path . 'language/lang_english/lang_admin.' . $phpEx ); + } + else + { + include( $module_root_path . 'language/lang_' . $board_config['default_lang'] . '/lang_admin.' . $phpEx ); + } + + $caltable = CALLITE_CONFIG_TABLE; $sql = "SELECT * FROM " . $caltable; *************** *** 128,132 **** "L_ALLOW_ANON" => $lang['allow_anon'], "L_ALLOW_USER_POST" => $lang['allow_user_post'], ! "L_ALLOW_ANON_DEFAULT" => $lang['allow_anon_post_default'], // MX005: added "L_ALLOW_USER_DEFAULT" => $lang['allow_user_post_default'], "L_ALLOW_OLD" => $lang['allow_old'], --- 140,144 ---- "L_ALLOW_ANON" => $lang['allow_anon'], "L_ALLOW_USER_POST" => $lang['allow_user_post'], ! "L_ALLOW_ANON_DEFAULT" => $lang['allow_anon_post_default'], "L_ALLOW_USER_DEFAULT" => $lang['allow_user_post_default'], "L_ALLOW_OLD" => $lang['allow_old'], |
|
From: Jon O. <jon...@us...> - 2006-06-29 22:03:26
|
Update of /cvsroot/mxbb/mx_calsnails/templates/subSilver In directory sc8-pr-cvs7.sourceforge.net:/tmp/cvs-serv27752/modules/mx_calsnails/templates/subSilver Modified Files: cal_view_month_mini.tpl Log Message: Installation bug adminCP lang keys initialization checks Index: cal_view_month_mini.tpl =================================================================== RCS file: /cvsroot/mxbb/mx_calsnails/templates/subSilver/cal_view_month_mini.tpl,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** cal_view_month_mini.tpl 5 Apr 2006 21:14:29 -0000 1.3 --- cal_view_month_mini.tpl 29 Jun 2006 22:03:22 -0000 1.4 *************** *** 5,8 **** --- 5,15 ---- </td> </tr> + <!-- BEGIN info --> + <tr> + <td class="row1" align="center" valign="middle" height="24"> + <span class="gen">This block is not correctly configured. Use the blockCP to define its target calsnails block.</span> + </td> + </tr> + <!-- END info --> <tr> <td> |
|
From: Jon O. <jon...@us...> - 2006-06-29 19:11:00
|
Update of /cvsroot/mxbb/mx_phpbb/includes In directory sc8-pr-cvs7.sourceforge.net:/tmp/cvs-serv21406/modules/mx_phpbb/includes Modified Files: forum_hack.php Log Message: fix Index: forum_hack.php =================================================================== RCS file: /cvsroot/mxbb/mx_phpbb/includes/forum_hack.php,v retrieving revision 1.12 retrieving revision 1.13 diff -C2 -d -r1.12 -r1.13 *** forum_hack.php 17 Jun 2006 20:22:44 -0000 1.12 --- forum_hack.php 29 Jun 2006 19:10:53 -0000 1.13 *************** *** 182,192 **** $mx_table_prefix = $this->_get_mx_table_name( '' ); $phpEx = substr(strrchr(__FILE__, '.'), 1); ! include_once( $mx_root_path . "includes/mx_constants.php"); // file of easy_parser class ! include_once( $mx_root_path . "includes/mx_functions.php"); // file of easy_parser class ! include_once( $mx_root_path . "includes/mx_functions_core.php"); // file of easy_parser class } - $news_setup = array(); - // // Query to find all mx_forum blocks - the forum_id select array --- 182,190 ---- $mx_table_prefix = $this->_get_mx_table_name( '' ); $phpEx = substr(strrchr(__FILE__, '.'), 1); ! include_once( $mx_root_path . "includes/mx_constants.php"); ! include_once( $mx_root_path . "includes/mx_functions.php"); ! include_once( $mx_root_path . "includes/mx_functions_core.php"); } // // Query to find all mx_forum blocks - the forum_id select array |
|
From: Jon O. <jon...@us...> - 2006-06-29 19:10:26
|
Update of /cvsroot/mxbb/mx_who_am_i In directory sc8-pr-cvs7.sourceforge.net:/tmp/cvs-serv21291/modules/mx_who_am_i Modified Files: mx_who_am_i.php Log Message: code cleanup Index: mx_who_am_i.php =================================================================== RCS file: /cvsroot/mxbb/mx_who_am_i/mx_who_am_i.php,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** mx_who_am_i.php 5 Apr 2006 23:03:18 -0000 1.4 --- mx_who_am_i.php 29 Jun 2006 19:10:10 -0000 1.5 *************** *** 25,29 **** | re...@di... | www.digitalhijinx.com ! | | description : The "Who Am I" block is a block is a block that | will be visable only to registered users who are --- 25,29 ---- | re...@di... | www.digitalhijinx.com ! | | description : The "Who Am I" block is a block is a block that | will be visable only to registered users who are *************** *** 45,49 **** | Security Section (Self Explainatory) \********************************************************************************/ - if (!defined('IN_PORTAL')) { --- 45,48 ---- *************** *** 61,64 **** | End Of Function (Self Explainatory) \********************************************************************************/ - ?> \ No newline at end of file --- 60,62 ---- |
|
From: Jon O. <jon...@us...> - 2006-06-29 19:10:26
|
Update of /cvsroot/mxbb/mx_who_am_i/includes In directory sc8-pr-cvs7.sourceforge.net:/tmp/cvs-serv21291/modules/mx_who_am_i/includes Modified Files: mx_common.php Log Message: code cleanup Index: mx_common.php =================================================================== RCS file: /cvsroot/mxbb/mx_who_am_i/includes/mx_common.php,v retrieving revision 1.5 retrieving revision 1.6 diff -C2 -d -r1.5 -r1.6 *** mx_common.php 5 Apr 2006 23:03:19 -0000 1.5 --- mx_common.php 29 Jun 2006 19:10:10 -0000 1.6 *************** *** 25,29 **** | re...@di... | www.digitalhijinx.com ! | | description : The "Who Am I" block is a block is a block that | will be visable only to registered users who are --- 25,29 ---- | re...@di... | www.digitalhijinx.com ! | | description : The "Who Am I" block is a block is a block that | will be visable only to registered users who are *************** *** 54,67 **** | Class Declaration Section (Classes) \********************************************************************************/ - class mx_who_am_i { ! var $regdate; ! var $memberdays; ! var $posts_per_day; var $percentage; var $total_posts; ! var $avatar_img; ! var $no_avatar_img; /********************************************************************************\ --- 54,66 ---- | Class Declaration Section (Classes) \********************************************************************************/ class mx_who_am_i { ! var $regdate; ! var $memberdays; ! var $posts_per_day; var $percentage; var $total_posts; ! var $avatar_img; ! var $no_avatar_img; /********************************************************************************\ *************** *** 74,83 **** global $userdata; ! $this->regdate = $userdata['user_regdate']; ! $this->memberdays = max(1, round((time() - $this->regdate) / 86400)); ! $this->posts_per_day = round($userdata['user_posts'] / $this->memberdays, 2); $this->percentage = 0; $this->total_posts = 0; ! $this->avatar_img = ''; $this->no_avatar_img = 'noavatar.png'; } --- 73,82 ---- global $userdata; ! $this->regdate = $userdata['user_regdate']; ! $this->memberdays = max(1, round((time() - $this->regdate) / 86400)); ! $this->posts_per_day = round($userdata['user_posts'] / $this->memberdays, 2); $this->percentage = 0; $this->total_posts = 0; ! $this->avatar_img = ''; $this->no_avatar_img = 'noavatar.png'; } *************** *** 96,125 **** if ($userdata['user_posts'] != 0) ! { ! $this->total_posts = get_db_stat('postcount'); ! $this->percentage = round(($this->total_posts) ? min(100, ($userdata['user_posts'] / $this->total_posts) * 100) : 0, 2); ! } ! else ! { $this->percentage = 0; ! } ! if ($userdata['user_avatar_type'] && $userdata['user_allowavatar']) ! { ! switch($userdata['user_avatar_type']) { ! case USER_AVATAR_UPLOAD: ! $this->avatar_img = '<img src=' . '"' . PHPBB_URL . $board_config['avatar_path'] . '/' . $userdata['user_avatar'] . '" alt="" border="0">'; ! break; ! case USER_AVATAR_REMOTE: ! $this->avatar_img = '<img src=' . '"' . $userdata['user_avatar'] . '" alt="" border="0">'; ! break; ! case USER_AVATAR_GALLERY: ! $this->avatar_img = '<img src=' . '"' . PHPBB_URL . $board_config['avatar_gallery_path'] . '/' . $userdata['user_avatar'] . '" alt="" border="0">'; ! break; } } ! if (empty($this->avatar_img)) { if (file_exists($module_root_path . 'templates/' . $theme['template_name'] . '/' . 'images/' . $this->no_avatar_img)) --- 95,124 ---- if ($userdata['user_posts'] != 0) ! { ! $this->total_posts = get_db_stat('postcount'); ! $this->percentage = round(($this->total_posts) ? min(100, ($userdata['user_posts'] / $this->total_posts) * 100) : 0, 2); ! } ! else ! { $this->percentage = 0; ! } ! if ($userdata['user_avatar_type'] && $userdata['user_allowavatar']) ! { ! switch($userdata['user_avatar_type']) { ! case USER_AVATAR_UPLOAD: ! $this->avatar_img = '<img src=' . '"' . PHPBB_URL . $board_config['avatar_path'] . '/' . $userdata['user_avatar'] . '" alt="" border="0">'; ! break; ! case USER_AVATAR_REMOTE: ! $this->avatar_img = '<img src=' . '"' . $userdata['user_avatar'] . '" alt="" border="0">'; ! break; ! case USER_AVATAR_GALLERY: ! $this->avatar_img = '<img src=' . '"' . PHPBB_URL . $board_config['avatar_gallery_path'] . '/' . $userdata['user_avatar'] . '" alt="" border="0">'; ! break; } } ! if (empty($this->avatar_img)) { if (file_exists($module_root_path . 'templates/' . $theme['template_name'] . '/' . 'images/' . $this->no_avatar_img)) *************** *** 177,188 **** 'L_POSTS_PER_DAY' => $lang['Posts_Per_Day'], ! 'USERNAME' => $userdata['username'], 'AVATAR_IMG' => '<a href="' . PHPBB_URL . 'profile.php?mode=viewprofile&u=' . $userdata['user_id'] . '">' . $this->avatar_img . '</a>', 'U_PROFILE' => append_sid(PHPBB_URL . 'profile.' . $phpEx . '?mode=editprofile'), ! 'JOINED' => create_date($lang['DATE_FORMAT'], $userdata['user_regdate'], $board_config['board_timezone']), ! 'POSTS' => $userdata['user_posts'], ! 'POST_PER_DAY' => $this->posts_per_day, 'POST_PERCENTAGE' => $this->percentage) ! ); $template->pparse('body_who_am_i'); --- 176,187 ---- 'L_POSTS_PER_DAY' => $lang['Posts_Per_Day'], ! 'USERNAME' => $userdata['username'], 'AVATAR_IMG' => '<a href="' . PHPBB_URL . 'profile.php?mode=viewprofile&u=' . $userdata['user_id'] . '">' . $this->avatar_img . '</a>', 'U_PROFILE' => append_sid(PHPBB_URL . 'profile.' . $phpEx . '?mode=editprofile'), ! 'JOINED' => create_date($lang['DATE_FORMAT'], $userdata['user_regdate'], $board_config['board_timezone']), ! 'POSTS' => $userdata['user_posts'], ! 'POST_PER_DAY' => $this->posts_per_day, 'POST_PERCENTAGE' => $this->percentage) ! ); $template->pparse('body_who_am_i'); *************** *** 203,207 **** | Main Body Section (Main Stuff) \********************************************************************************/ - $who_am_i = new mx_who_am_i; --- 202,205 ---- *************** *** 209,212 **** | End Of Function (Self Explainatory) \********************************************************************************/ - ?> \ No newline at end of file --- 207,209 ---- |
|
From: Jon O. <jon...@us...> - 2006-06-29 19:08:51
|
Update of /cvsroot/mxbb/mx_sitestats/includes In directory sc8-pr-cvs7.sourceforge.net:/tmp/cvs-serv19996/modules/mx_sitestats/includes Modified Files: common.php Log Message: code cleanup Index: common.php =================================================================== RCS file: /cvsroot/mxbb/mx_sitestats/includes/common.php,v retrieving revision 1.6 retrieving revision 1.7 diff -C2 -d -r1.6 -r1.7 *** common.php 17 Jun 2006 20:51:08 -0000 1.6 --- common.php 29 Jun 2006 19:08:04 -0000 1.7 *************** *** 16,21 **** define( '_SITESTATS_VERSION', 'v1.3.0' ); // Define table names. ! if ( empty( $mx_table_prefix ) ) { --- 16,22 ---- define( '_SITESTATS_VERSION', 'v1.3.0' ); + // // Define table names. ! // if ( empty( $mx_table_prefix ) ) { *************** *** 34,43 **** $mx_table_prefix = get_mx_table_prefix( $mx_root_path ); } define( 'SITESTATS_CONFIG_TABLE', $mx_table_prefix . 'sitestats_config' ); define( 'SITESTATS_COUNTER_TABLE', $mx_table_prefix . 'sitestats_counter' ); define( 'SITESTATS_REFERER_TABLE', $mx_table_prefix . 'sitestats_referer' ); // Load language files. ! if ( file_exists( $module_root_path . 'language/lang_' . $board_config['default_lang'] . '/lang_admin.' . $phpEx ) ) { --- 35,49 ---- $mx_table_prefix = get_mx_table_prefix( $mx_root_path ); } + + // + // Definitions + // define( 'SITESTATS_CONFIG_TABLE', $mx_table_prefix . 'sitestats_config' ); define( 'SITESTATS_COUNTER_TABLE', $mx_table_prefix . 'sitestats_counter' ); define( 'SITESTATS_REFERER_TABLE', $mx_table_prefix . 'sitestats_referer' ); + // // Load language files. ! // if ( file_exists( $module_root_path . 'language/lang_' . $board_config['default_lang'] . '/lang_admin.' . $phpEx ) ) { *************** *** 57,66 **** include_once( $module_root_path . 'language/lang_english/lang_main.' . $phpEx ); } // ================================================================================ // [ SITESTATS CONFIG ] // ================================================================================ - // Get SiteStats Settings from config table ! if ( defined( '_SITESTATS_CONFIG' ) ) { --- 63,72 ---- include_once( $module_root_path . 'language/lang_english/lang_main.' . $phpEx ); } + // ================================================================================ // [ SITESTATS CONFIG ] // ================================================================================ // Get SiteStats Settings from config table ! // if ( defined( '_SITESTATS_CONFIG' ) ) { *************** *** 80,85 **** } // Set Default Configuration (safety)... ! if ( empty( $sitestats_config['text_class'] ) ) { --- 86,92 ---- } + // // Set Default Configuration (safety)... ! // if ( empty( $sitestats_config['text_class'] ) ) { *************** *** 111,117 **** // Site Statistics Classes ! // Base class with DB Utilities ! class sitestats { --- 118,124 ---- // Site Statistics Classes ! // // Base class with DB Utilities ! // class sitestats { *************** *** 125,128 **** --- 132,136 ---- return $result; } + function dbFetchRow( $sql ) { *************** *** 135,138 **** --- 143,147 ---- return $row; } + function dbMaxId( $table_name, $table_key ) { *************** *** 150,156 **** class sitestats_counter extends sitestats { ! // Public Properties ! var $id, // Internal page identifier. $page, // Human page identifier. --- 159,165 ---- class sitestats_counter extends sitestats { ! // // Public Properties ! // var $id, // Internal page identifier. $page, // Human page identifier. *************** *** 161,167 **** $digits_ext; // File Extension for current digit images. ! // Constructor... ! function sitestats_counter() { --- 170,176 ---- $digits_ext; // File Extension for current digit images. ! // // Constructor... ! // function sitestats_counter() { *************** *** 182,187 **** } // Public Methods related to the Counter... ! function readCounter( $page ) { --- 191,197 ---- } + // // Public Methods related to the Counter... ! // function readCounter( $page ) { *************** *** 201,204 **** --- 211,215 ---- return true; } + function incrementCounter() { *************** *** 212,222 **** } } function updateCounter() { if ( $this->id == 0 ) { ! // There is still no counter for this page? ! $this->id = $this->dbMaxId( SITESTATS_COUNTER_TABLE, 'id' ); if ( empty( $this->id ) ) --- 223,234 ---- } } + function updateCounter() { if ( $this->id == 0 ) { ! // // There is still no counter for this page? ! // $this->id = $this->dbMaxId( SITESTATS_COUNTER_TABLE, 'id' ); if ( empty( $this->id ) ) *************** *** 227,237 **** else { ! // Update the hits counter for this page... ! $sql = 'UPDATE ' . SITESTATS_COUNTER_TABLE . " SET page = '" . $this->page . "' , " . ' hits_counter = ' . $this->hits_counter . ' , ' . ' sess_counter = ' . $this->sess_counter . ' WHERE id = ' . $this->id; } return $this->dbQuery( $sql ) ? true : false; } function deleteCounter() { --- 239,250 ---- else { ! // // Update the hits counter for this page... ! // $sql = 'UPDATE ' . SITESTATS_COUNTER_TABLE . " SET page = '" . $this->page . "' , " . ' hits_counter = ' . $this->hits_counter . ' , ' . ' sess_counter = ' . $this->sess_counter . ' WHERE id = ' . $this->id; } return $this->dbQuery( $sql ) ? true : false; } + function deleteCounter() { *************** *** 240,245 **** } // Public Methods related to Counter Images... ! function _getDigitsExt() { --- 253,259 ---- } + // // Public Methods related to Counter Images... ! // function _getDigitsExt() { *************** *** 250,253 **** --- 264,268 ---- return ''; } + function setDigitParms( $digits_path, $digits_style ) { *************** *** 260,263 **** --- 275,279 ---- return true; } + function getCounterImages( $counter, $size, $get_image_size ) { *************** *** 279,282 **** --- 295,299 ---- return $r; } + function getDigitStyles( $digits_path ) { *************** *** 300,305 **** } // Public Methods related to HTTP Referer... ! function updateReferer() { --- 317,323 ---- } + // // Public Methods related to HTTP Referer... ! // function updateReferer() { *************** *** 337,342 **** var $text_class; // Constructor ! function sitestats_phpbb() { --- 355,361 ---- var $text_class; + // // Constructor ! // function sitestats_phpbb() { *************** *** 349,354 **** } // Basic phpBB statistics... ! function get_db_stat( $mode ) { --- 368,374 ---- } + // // Basic phpBB statistics... ! // function get_db_stat( $mode ) { *************** *** 360,365 **** } // Compute the percent math... ! function do_percent_math( $firstval, $value, $total ) { --- 380,386 ---- } + // // Compute the percent math... ! // function do_percent_math( $firstval, $value, $total ) { *************** *** 373,378 **** } // Get voting bar info and Set templates variables... ! function set_voting_bar() { --- 394,400 ---- } + // // Get voting bar info and Set templates variables... ! // function set_voting_bar() { *************** *** 392,395 **** $mxbb_footer_addup[] = 'mxBB Sitestats Module'; - ?> \ No newline at end of file --- 414,416 ---- |
Update of /cvsroot/mxbb/mx_sitestats In directory sc8-pr-cvs7.sourceforge.net:/tmp/cvs-serv19996/modules/mx_sitestats Modified Files: adminstats.php collector.php counter.php db_install.php db_uninstall.php db_upgrade.php fastestusers.php monthlyposts.php monthlytopics.php monthlyusers.php mostintopics.php sitestaff.php topavatars.php topposters.php topposters_tiny.php topreferers.php topsmilies.php topstarters.php toptopics.php topwords.php usersranks.php Log Message: code cleanup Index: topwords.php =================================================================== RCS file: /cvsroot/mxbb/mx_sitestats/topwords.php,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** topwords.php 5 Apr 2006 23:03:45 -0000 1.4 --- topwords.php 29 Jun 2006 19:08:04 -0000 1.5 *************** *** 23,28 **** } // Include common module stuff... ! include_once( $module_root_path . 'includes/common.' . $phpEx ); --- 23,29 ---- } + // // Include common module stuff... ! // include_once( $module_root_path . 'includes/common.' . $phpEx ); *************** *** 36,55 **** $ss_phpbb = new sitestats_phpbb(); } // -------------------------------------------------------------------------------- // Block Procedure // -------------------------------------------------------------------------------- // This is the template used to render this block. ! $template->set_filenames( array( 'body' => 'sitestats_topwords_body.tpl' ) ! ); ! // Top Words ! $sql = 'SELECT COUNT( word_id ) AS total_words FROM ' . SEARCH_MATCH_TABLE; if ( !$result = $db->sql_query( $sql ) ) { mx_message_die( GENERAL_ERROR, "Couldn't retrieve words data", "", __LINE__, __FILE__, $sql ); } $words_data = $db->sql_fetchrowset( $result ); $total_words = $words_data[0]['total_words']; --- 37,60 ---- $ss_phpbb = new sitestats_phpbb(); } + // -------------------------------------------------------------------------------- // Block Procedure // -------------------------------------------------------------------------------- + // // This is the template used to render this block. + // + $template->set_filenames( array( 'body' => 'sitestats_topwords_body.tpl' ) ); ! // // Top Words ! // $sql = 'SELECT COUNT( word_id ) AS total_words FROM ' . SEARCH_MATCH_TABLE; + if ( !$result = $db->sql_query( $sql ) ) { mx_message_die( GENERAL_ERROR, "Couldn't retrieve words data", "", __LINE__, __FILE__, $sql ); } + $words_data = $db->sql_fetchrowset( $result ); $total_words = $words_data[0]['total_words']; *************** *** 60,67 **** --- 65,74 ---- ORDER BY word_count DESC LIMIT ' . $ss_phpbb->return_limit * 10; + if ( !$result = $db->sql_query( $sql ) ) { mx_message_die( GENERAL_ERROR, "Couldn't retrieve words data", "", __LINE__, __FILE__, $sql ); } + $words_count = $db->sql_numrows( $result ); $words_data = $db->sql_fetchrowset( $result ); *************** *** 91,101 **** $percent_array = $ss_phpbb->do_percent_math( $firstcount, $words_data[$i]['word_count'], $total_words ); ! $template->assign_block_vars( 'datarow', array( 'RANK' => $j, ! 'CLASS' => ( !( $j + 1 % 2 ) ) ? $theme['td_class2'] : $theme['td_class1'], ! 'USES' => $words_data[$i]['word_count'], ! 'PERCENTAGE' => $percent_array['percentage'], ! 'BAR' => $percent_array['bar_percent'], ! 'WORD' => $words_data[$i]['word_text'] ) ! ); $j++; } --- 98,109 ---- $percent_array = $ss_phpbb->do_percent_math( $firstcount, $words_data[$i]['word_count'], $total_words ); ! $template->assign_block_vars( 'datarow', array( ! 'RANK' => $j, ! 'CLASS' => ( !( $j + 1 % 2 ) ) ? $theme['td_class2'] : $theme['td_class1'], ! 'USES' => $words_data[$i]['word_count'], ! 'PERCENTAGE' => $percent_array['percentage'], ! 'BAR' => $percent_array['bar_percent'], ! 'WORD' => $words_data[$i]['word_text'] ) ! ); $j++; } *************** *** 107,120 **** // Setup common template vars and display the block. ! $template->assign_vars( array( 'L_USES' => $lang['Uses'], ! 'L_RANK' => $lang['Rank'], ! 'L_PERCENTAGE' => $lang['Percent'], ! 'L_GRAPH' => $lang['Graph'], ! 'L_WORD' => $lang['Word'], ! 'TEXT_CLASS' => $ss_phpbb->text_class, ! 'L_TITLE' => $lang['Top_Words'] ) ! ); ! $template->pparse( 'body' ); ! ?> --- 115,129 ---- // Setup common template vars and display the block. ! $template->assign_vars( array( ! 'L_USES' => $lang['Uses'], ! 'L_RANK' => $lang['Rank'], ! 'L_PERCENTAGE' => $lang['Percent'], ! 'L_GRAPH' => $lang['Graph'], ! 'L_WORD' => $lang['Word'], ! 'TEXT_CLASS' => $ss_phpbb->text_class, ! 'L_TITLE' => $lang['Top_Words'] ) ! ); ! $template->pparse( 'body' ); ! ?> \ No newline at end of file Index: usersranks.php =================================================================== RCS file: /cvsroot/mxbb/mx_sitestats/usersranks.php,v retrieving revision 1.5 retrieving revision 1.6 diff -C2 -d -r1.5 -r1.6 *** usersranks.php 2 May 2006 23:29:13 -0000 1.5 --- usersranks.php 29 Jun 2006 19:08:04 -0000 1.6 *************** *** 23,28 **** } // Include common module stuff... ! include_once( $module_root_path . 'includes/common.' . $phpEx ); --- 23,29 ---- } + // // Include common module stuff... ! // include_once( $module_root_path . 'includes/common.' . $phpEx ); *************** *** 36,56 **** $ss_phpbb = new sitestats_phpbb(); } // -------------------------------------------------------------------------------- // Block Procedure // -------------------------------------------------------------------------------- // This is the template used to render this block. ! $template->set_filenames( array( 'body' => 'sitestats_usersranks_body.tpl' ) ! ); ! // Users Ranks ! $sql = 'SELECT * FROM ' . RANKS_TABLE . ' ORDER BY rank_min, rank_title'; if ( !$result = $db->sql_query( $sql ) ) { mx_message_die( GENERAL_ERROR, "Couldn't retrieve ranks data", '', __LINE__, __FILE__, $sql ); } $ranks_count = $db->sql_numrows( $result ); $ranks_data = $db->sql_fetchrowset( $result ); --- 37,61 ---- $ss_phpbb = new sitestats_phpbb(); } + // -------------------------------------------------------------------------------- // Block Procedure // -------------------------------------------------------------------------------- + // // This is the template used to render this block. + // + $template->set_filenames( array( 'body' => 'sitestats_usersranks_body.tpl' ) ); ! // // Users Ranks ! // $sql = 'SELECT * FROM ' . RANKS_TABLE . ' ORDER BY rank_min, rank_title'; + if ( !$result = $db->sql_query( $sql ) ) { mx_message_die( GENERAL_ERROR, "Couldn't retrieve ranks data", '', __LINE__, __FILE__, $sql ); } + $ranks_count = $db->sql_numrows( $result ); $ranks_data = $db->sql_fetchrowset( $result ); *************** *** 113,124 **** { $percent_array = $ss_phpbb->do_percent_math( $firstcount, $ranks_data[$i]['used_counter'], $total_users ); ! $template->assign_block_vars( 'datarow', array( 'RANK' => $i + 1, ! 'CLASS' => ( !( $i + 1 % 2 ) ) ? $theme['td_class2'] : $theme['td_class1'], ! 'RANK_TITLE_IMAGE' => $ranks_data[$i]['rank_title'] . '<br />' . $ranks_data[$i]['rank_img'], ! 'RANK_RANGE' => $ranks_data[$i]['posts_range'], ! 'USERS' => $ranks_data[$i]['used_counter'], ! 'PERCENTAGE' => $percent_array['percentage'], ! 'BAR' => $percent_array['bar_percent'] ) ! ); } } --- 118,131 ---- { $percent_array = $ss_phpbb->do_percent_math( $firstcount, $ranks_data[$i]['used_counter'], $total_users ); ! ! $template->assign_block_vars( 'datarow', array( ! 'RANK' => $i + 1, ! 'CLASS' => ( !( $i + 1 % 2 ) ) ? $theme['td_class2'] : $theme['td_class1'], ! 'RANK_TITLE_IMAGE' => $ranks_data[$i]['rank_title'] . '<br />' . $ranks_data[$i]['rank_img'], ! 'RANK_RANGE' => $ranks_data[$i]['posts_range'], ! 'USERS' => $ranks_data[$i]['used_counter'], ! 'PERCENTAGE' => $percent_array['percentage'], ! 'BAR' => $percent_array['bar_percent'] ) ! ); } } *************** *** 128,159 **** { $percent_array = $ss_phpbb->do_percent_math( $firstcount, $ranks_data[$i]['used_counter'], $total_users ); ! $template->assign_block_vars( 'datarow', array( 'RANK' => $i + 1, ! 'CLASS' => ( !( $i + 1 % 2 ) ) ? $theme['td_class2'] : $theme['td_class1'], ! 'RANK_TITLE_IMAGE' => $ranks_data[$i]['rank_title'] . '<br />' . $ranks_data[$i]['rank_img'], ! 'RANK_RANGE' => $ranks_data[$i]['posts_range'], ! 'USERS' => $ranks_data[$i]['used_counter'], ! 'PERCENTAGE' => $percent_array['percentage'], ! 'BAR' => $percent_array['bar_percent'] ) ! ); } } // Setup voting bar images... ! $ss_phpbb->set_voting_bar(); // Setup common template vars and display the block. ! $template->assign_vars( array( 'L_RANK' => $lang['Rank'], ! 'L_RANK_TITLE_IMAGE' => $lang['Rank_Title_Image'], ! 'L_RANK_RANGE' => $lang['Rank_range'], ! 'L_USERS' => $lang['Uses'], ! 'L_PERCENTAGE' => $lang['Percent'], ! 'L_GRAPH' => $lang['Graph'], - 'TEXT_CLASS' => $ss_phpbb->text_class, - 'L_TITLE' => $lang['Users_Ranks'] ) - ); $template->pparse( 'body' ); ! ! ?> --- 135,171 ---- { $percent_array = $ss_phpbb->do_percent_math( $firstcount, $ranks_data[$i]['used_counter'], $total_users ); ! ! $template->assign_block_vars( 'datarow', array( ! 'RANK' => $i + 1, ! 'CLASS' => ( !( $i + 1 % 2 ) ) ? $theme['td_class2'] : $theme['td_class1'], ! 'RANK_TITLE_IMAGE' => $ranks_data[$i]['rank_title'] . '<br />' . $ranks_data[$i]['rank_img'], ! 'RANK_RANGE' => $ranks_data[$i]['posts_range'], ! 'USERS' => $ranks_data[$i]['used_counter'], ! 'PERCENTAGE' => $percent_array['percentage'], ! 'BAR' => $percent_array['bar_percent'] ) ! ); } } + // // Setup voting bar images... ! // $ss_phpbb->set_voting_bar(); + // // Setup common template vars and display the block. + // + $template->assign_vars( array( + 'L_RANK' => $lang['Rank'], + 'L_RANK_TITLE_IMAGE' => $lang['Rank_Title_Image'], + 'L_RANK_RANGE' => $lang['Rank_range'], + 'L_USERS' => $lang['Uses'], + 'L_PERCENTAGE' => $lang['Percent'], + 'L_GRAPH' => $lang['Graph'], ! 'TEXT_CLASS' => $ss_phpbb->text_class, ! 'L_TITLE' => $lang['Users_Ranks'] ) ! ); $template->pparse( 'body' ); ! ?> \ No newline at end of file Index: db_upgrade.php =================================================================== RCS file: /cvsroot/mxbb/mx_sitestats/db_upgrade.php,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** db_upgrade.php 2 May 2006 23:29:13 -0000 1.4 --- db_upgrade.php 29 Jun 2006 19:08:04 -0000 1.5 *************** *** 30,33 **** --- 30,36 ---- } + // + // + // $mx_module_version = '2.0.0'; $mx_module_copy = 'Original mxBB <i>SiteStats</i> module by <a href="http://www.phpmix.com" target="_blank">Markus</a>'; *************** *** 50,53 **** echo "<tr><td class=\"row1\" align=\"left\"><span class=\"gen\">" . $message . "</span></td></tr>"; echo "</table><br />"; - ?> \ No newline at end of file --- 53,55 ---- Index: topstarters.php =================================================================== RCS file: /cvsroot/mxbb/mx_sitestats/topstarters.php,v retrieving revision 1.5 retrieving revision 1.6 diff -C2 -d -r1.5 -r1.6 *** topstarters.php 2 May 2006 23:29:13 -0000 1.5 --- topstarters.php 29 Jun 2006 19:08:04 -0000 1.6 *************** *** 23,28 **** } // Include common module stuff... ! include_once( $module_root_path . 'includes/common.' . $phpEx ); --- 23,29 ---- } + // // Include common module stuff... ! // include_once( $module_root_path . 'includes/common.' . $phpEx ); *************** *** 36,50 **** $ss_phpbb = new sitestats_phpbb(); } // -------------------------------------------------------------------------------- // Block Procedure // -------------------------------------------------------------------------------- // This is the template used to render this block. ! $template->set_filenames( array( 'body' => 'sitestats_topstarters_body.tpl' ) ! ); ! // Most Active Topic Starters ! $sql = 'SELECT u.user_id, u.username, COUNT(t.topic_poster) AS num_topics FROM ' . USERS_TABLE . ' u, ' . TOPICS_TABLE . ' t --- 37,53 ---- $ss_phpbb = new sitestats_phpbb(); } + // -------------------------------------------------------------------------------- // Block Procedure // -------------------------------------------------------------------------------- + // // This is the template used to render this block. + // + $template->set_filenames( array( 'body' => 'sitestats_topstarters_body.tpl' ) ); ! // // Most Active Topic Starters ! // $sql = 'SELECT u.user_id, u.username, COUNT(t.topic_poster) AS num_topics FROM ' . USERS_TABLE . ' u, ' . TOPICS_TABLE . ' t *************** *** 52,59 **** --- 55,64 ---- GROUP BY t.topic_poster ORDER BY num_topics DESC LIMIT ' . $ss_phpbb->return_limit; + if ( !( $result = $db->sql_query( $sql ) ) ) { mx_message_die( GENERAL_ERROR, "Couldn't retrieve users data", '', __LINE__, __FILE__, $sql ); } + $user_count = $db->sql_numrows( $result ); $user_data = $db->sql_fetchrowset( $result ); *************** *** 67,96 **** $percent_array = $ss_phpbb->do_percent_math( $firstcount, $user_data[$i]['num_topics'], $total_topics ); ! $template->assign_block_vars( 'datarow', array( 'RANK' => $i + 1, ! 'CLASS' => ( !( $i + 1 % 2 ) ) ? $theme['td_class2'] : $theme['td_class1'], ! 'USERNAME' => $user_data[$i]['username'], ! 'PERCENTAGE' => $percent_array['percentage'], ! 'BAR' => $percent_array['bar_percent'], ! 'URL' => append_sid( PHPBB_URL . 'profile.php?mode=viewprofile&u=' . $user_data[$i]['user_id'] ), ! 'TOPICS' => $user_data[$i]['num_topics'] ) ! ); } // Setup voting bar images... ! $ss_phpbb->set_voting_bar(); // Setup common template vars and display the block. ! $template->assign_vars( array( 'L_TOPICS' => $lang['Topics'], ! 'L_RANK' => $lang['Rank'], ! 'L_PERCENTAGE' => $lang['Percent'], ! 'L_GRAPH' => $lang['Graph'], ! 'L_USERNAME' => $lang['Username'], - 'TEXT_CLASS' => $ss_phpbb->text_class, - 'L_TITLE' => $lang['Top_Starters'] ) - ); $template->pparse( 'body' ); ! ! ?> --- 72,105 ---- $percent_array = $ss_phpbb->do_percent_math( $firstcount, $user_data[$i]['num_topics'], $total_topics ); ! $template->assign_block_vars( 'datarow', array( ! 'RANK' => $i + 1, ! 'CLASS' => ( !( $i + 1 % 2 ) ) ? $theme['td_class2'] : $theme['td_class1'], ! 'USERNAME' => $user_data[$i]['username'], ! 'PERCENTAGE' => $percent_array['percentage'], ! 'BAR' => $percent_array['bar_percent'], ! 'URL' => append_sid( PHPBB_URL . 'profile.php?mode=viewprofile&u=' . $user_data[$i]['user_id'] ), ! 'TOPICS' => $user_data[$i]['num_topics'] ) ! ); } + // // Setup voting bar images... ! // $ss_phpbb->set_voting_bar(); + // // Setup common template vars and display the block. + // + $template->assign_vars( array( + 'L_TOPICS' => $lang['Topics'], + 'L_RANK' => $lang['Rank'], + 'L_PERCENTAGE' => $lang['Percent'], + 'L_GRAPH' => $lang['Graph'], + 'L_USERNAME' => $lang['Username'], ! 'TEXT_CLASS' => $ss_phpbb->text_class, ! 'L_TITLE' => $lang['Top_Starters'] ) ! ); $template->pparse( 'body' ); ! ?> \ No newline at end of file Index: topavatars.php =================================================================== RCS file: /cvsroot/mxbb/mx_sitestats/topavatars.php,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** topavatars.php 5 Apr 2006 23:03:45 -0000 1.4 --- topavatars.php 29 Jun 2006 19:08:04 -0000 1.5 *************** *** 23,28 **** } // Include common module stuff... ! include_once( $module_root_path . 'includes/common.' . $phpEx ); --- 23,29 ---- } + // // Include common module stuff... ! // include_once( $module_root_path . 'includes/common.' . $phpEx ); *************** *** 36,58 **** $ss_phpbb = new sitestats_phpbb(); } // -------------------------------------------------------------------------------- // Block Procedure // -------------------------------------------------------------------------------- // This is the template used to render this block. ! $template->set_filenames( array( 'body' => 'sitestats_topavatars_body.tpl' ) ! ); ! // Top Avatars ! $sql = "SELECT COUNT(user_avatar) AS used_counter, user_avatar FROM " . USERS_TABLE . " ! WHERE user_avatar_type = " . USER_AVATAR_GALLERY . " GROUP BY user_avatar ORDER BY used_counter DESC LIMIT " . $ss_phpbb->return_limit; if ( !$result = $db->sql_query( $sql ) ) { mx_message_die( GENERAL_ERROR, "Couldn't retrieve users data", "", __LINE__, __FILE__, $sql ); } $user_count = $db->sql_numrows( $result ); $user_data = $db->sql_fetchrowset( $result ); --- 37,63 ---- $ss_phpbb = new sitestats_phpbb(); } + // -------------------------------------------------------------------------------- // Block Procedure // -------------------------------------------------------------------------------- + // // This is the template used to render this block. + // + $template->set_filenames( array( 'body' => 'sitestats_topavatars_body.tpl' ) ); ! // // Top Avatars ! // $sql = "SELECT COUNT(user_avatar) AS used_counter, user_avatar FROM " . USERS_TABLE . " ! WHERE user_avatar_type = " . USER_AVATAR_GALLERY . " GROUP BY user_avatar ORDER BY used_counter DESC LIMIT " . $ss_phpbb->return_limit; + if ( !$result = $db->sql_query( $sql ) ) { mx_message_die( GENERAL_ERROR, "Couldn't retrieve users data", "", __LINE__, __FILE__, $sql ); } + $user_count = $db->sql_numrows( $result ); $user_data = $db->sql_fetchrowset( $result ); *************** *** 63,91 **** $percent_array = $ss_phpbb->do_percent_math( $firstcount, $user_data[$i]['used_counter'], $user_count ); ! $template->assign_block_vars( 'datarow', array( 'RANK' => $i + 1, ! 'CLASS' => ( !( $i + 1 % 2 ) ) ? $theme['td_class2'] : $theme['td_class1'], ! 'USES' => $user_data[$i]['used_counter'], ! 'PERCENTAGE' => $percent_array['percentage'], ! 'BAR' => $percent_array['bar_percent'], ! 'URL' => '<img src="' . PHPBB_URL . $board_config['avatar_gallery_path'] . '/' . $user_data[$i]['user_avatar'] . '" alt="' . $user_data[$i]['user_avatar'] . '" border="0" />' ) ! ); } // Setup voting bar images... ! $ss_phpbb->set_voting_bar(); // Setup common template vars and display the block. ! $template->assign_vars( array( 'L_USES' => $lang['Uses'], ! 'L_RANK' => $lang['Rank'], ! 'L_PERCENTAGE' => $lang['Percent'], ! 'L_GRAPH' => $lang['Graph'], ! 'L_AVATAR' => $lang['Avatar'], - 'TEXT_CLASS' => $ss_phpbb->text_class, - 'L_TITLE' => $lang['Top_Avatars'] ) - ); $template->pparse( 'body' ); ! ! ?> --- 68,100 ---- $percent_array = $ss_phpbb->do_percent_math( $firstcount, $user_data[$i]['used_counter'], $user_count ); ! $template->assign_block_vars( 'datarow', array( ! 'RANK' => $i + 1, ! 'CLASS' => ( !( $i + 1 % 2 ) ) ? $theme['td_class2'] : $theme['td_class1'], ! 'USES' => $user_data[$i]['used_counter'], ! 'PERCENTAGE' => $percent_array['percentage'], ! 'BAR' => $percent_array['bar_percent'], ! 'URL' => '<img src="' . PHPBB_URL . $board_config['avatar_gallery_path'] . '/' . $user_data[$i]['user_avatar'] . '" alt="' . $user_data[$i]['user_avatar'] . '" border="0" />' ) ! ); } + // // Setup voting bar images... ! // $ss_phpbb->set_voting_bar(); + // // Setup common template vars and display the block. + // + $template->assign_vars( array( + 'L_USES' => $lang['Uses'], + 'L_RANK' => $lang['Rank'], + 'L_PERCENTAGE' => $lang['Percent'], + 'L_GRAPH' => $lang['Graph'], + 'L_AVATAR' => $lang['Avatar'], ! 'TEXT_CLASS' => $ss_phpbb->text_class, ! 'L_TITLE' => $lang['Top_Avatars'] ) ! ); $template->pparse( 'body' ); ! ?> \ No newline at end of file Index: collector.php =================================================================== RCS file: /cvsroot/mxbb/mx_sitestats/collector.php,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** collector.php 5 Apr 2006 23:03:45 -0000 1.4 --- collector.php 29 Jun 2006 19:08:04 -0000 1.5 *************** *** 14,19 **** */ // Security check... ! if ( !defined( 'IN_PORTAL' ) && !defined( 'IN_PHPBB' ) || !is_object($mx_block) ) { --- 14,20 ---- */ + // // Security check... ! // if ( !defined( 'IN_PORTAL' ) && !defined( 'IN_PHPBB' ) || !is_object($mx_block) ) { *************** *** 21,26 **** } // Common Includes and Read Static Module Settings ! define( '_SITESTATS_CONFIG', true ); $module_root_save = $module_root_path; --- 22,28 ---- } + // // Common Includes and Read Static Module Settings ! // define( '_SITESTATS_CONFIG', true ); $module_root_save = $module_root_path; *************** *** 35,40 **** $module_root_path = $module_root_save; // Update the Counters... ! $sitestats_counter = new sitestats_counter(); $sitestats_counter->readCounter( $board_config['sitename'] ); --- 37,43 ---- $module_root_path = $module_root_save; + // // Update the Counters... ! // $sitestats_counter = new sitestats_counter(); $sitestats_counter->readCounter( $board_config['sitename'] ); *************** *** 49,54 **** } // Update HTTP Referer... ! if ( $sitestats_config['referers_logging'] ) { --- 52,58 ---- } + // // Update HTTP Referer... ! // if ( $sitestats_config['referers_logging'] ) { *************** *** 61,64 **** } } - ?> \ No newline at end of file --- 65,67 ---- Index: db_uninstall.php =================================================================== RCS file: /cvsroot/mxbb/mx_sitestats/db_uninstall.php,v retrieving revision 1.5 retrieving revision 1.6 diff -C2 -d -r1.5 -r1.6 *** db_uninstall.php 2 May 2006 23:29:13 -0000 1.5 --- db_uninstall.php 29 Jun 2006 19:08:04 -0000 1.6 *************** *** 30,34 **** --- 30,36 ---- } + // // Read module constants... + // $module_root_path = dirname( __FILE__ ) . '/'; include_once( $module_root_path . 'includes/common.' . $phpEx ); Index: db_install.php =================================================================== RCS file: /cvsroot/mxbb/mx_sitestats/db_install.php,v retrieving revision 1.6 retrieving revision 1.7 diff -C2 -d -r1.6 -r1.7 *** db_install.php 2 May 2006 23:29:13 -0000 1.6 --- db_install.php 29 Jun 2006 19:08:04 -0000 1.7 *************** *** 33,37 **** --- 33,39 ---- $mx_module_copy = 'Original mxBB <i>SiteStats</i> module by <a href="http://www.phpmix.com" target="_blank">Markus</a>'; + // // Read module constants... + // $module_root_path = dirname( __FILE__ ) . '/'; include_once( $module_root_path . 'includes/common.' . $phpEx ); Index: topsmilies.php =================================================================== RCS file: /cvsroot/mxbb/mx_sitestats/topsmilies.php,v retrieving revision 1.5 retrieving revision 1.6 diff -C2 -d -r1.5 -r1.6 *** topsmilies.php 2 May 2006 23:29:13 -0000 1.5 --- topsmilies.php 29 Jun 2006 19:08:04 -0000 1.6 *************** *** 23,28 **** } // Include common module stuff... ! include_once( $module_root_path . 'includes/common.' . $phpEx ); --- 23,29 ---- } + // // Include common module stuff... ! // include_once( $module_root_path . 'includes/common.' . $phpEx ); *************** *** 36,58 **** $ss_phpbb = new sitestats_phpbb(); } // -------------------------------------------------------------------------------- // Block Procedure // -------------------------------------------------------------------------------- // This is the template used to render this block. ! $template->set_filenames( array( 'body' => 'sitestats_topsmilies_body.tpl' ) ! ); ! // Top Smilies ! ! // Set smile_pref to 0, if you want that smilies are only counted once per post. // This means that, if the same smilie is entered ten times in a message, only one is counted in that message. ! $smile_pref = 1; // sort multi-dimensional array - from File Attachment Mod ! function smilies_sort_multi_array_attachment ( $sort_array, $key, $sort_order ) { --- 37,62 ---- $ss_phpbb = new sitestats_phpbb(); } + // -------------------------------------------------------------------------------- // Block Procedure // -------------------------------------------------------------------------------- + // // This is the template used to render this block. + // + $template->set_filenames( array( 'body' => 'sitestats_topsmilies_body.tpl' ) ); ! // // Top Smilies ! // ! // // Set smile_pref to 0, if you want that smilies are only counted once per post. // This means that, if the same smilie is entered ten times in a message, only one is counted in that message. ! // $smile_pref = 1; + // // sort multi-dimensional array - from File Attachment Mod ! // function smilies_sort_multi_array_attachment ( $sort_array, $key, $sort_order ) { *************** *** 65,72 **** for( $j = 0; $j < $num_iterations; $j++ ) { ! $next = 0; ! // do checks based on key ! $switch = false; if ( !( $string_sort ) ) --- 69,76 ---- for( $j = 0; $j < $num_iterations; $j++ ) { ! $next = 0; ! // do checks based on key ! $switch = false; if ( !( $string_sort ) ) *************** *** 95,100 **** } // Most used smilies ! $sql = 'SELECT smile_url FROM ' . SMILIES_TABLE . ' GROUP BY smile_url'; if ( !( $result = $db->sql_query( $sql ) ) ) --- 99,105 ---- } + // // Most used smilies ! // $sql = 'SELECT smile_url FROM ' . SMILIES_TABLE . ' GROUP BY smile_url'; if ( !( $result = $db->sql_query( $sql ) ) ) *************** *** 147,151 **** --- 152,159 ---- } } + + // // Sort array + // $all_smilies = smilies_sort_multi_array_attachment( $all_smilies, 'count', 'DESC' ); *************** *** 158,189 **** $percent_array = $ss_phpbb->do_percent_math( $all_smilies[0]['count'], $all_smilies[$i]['count'], $total_smilies ); ! $template->assign_block_vars( 'datarow', array( 'RANK' => $i + 1, ! 'CLASS' => ( !( $i + 1 % 2 ) ) ? $theme['td_class2'] : $theme['td_class1'], ! 'CODE' => $all_smilies[$i]['code'], ! 'USES' => $all_smilies[$i]['count'], ! 'PERCENTAGE' => $percent_array['percentage'], ! 'BAR' => $percent_array['bar_percent'], ! 'URL' => '<img src="' . PHPBB_URL . $board_config['smilies_path'] . '/' . $all_smilies[$i]['smile_url'] . '" alt="' . $all_smilies[$i]['smile_url'] . '" border="0" />' ) ! ); } } // Setup voting bar images... ! $ss_phpbb->set_voting_bar(); // Setup common template vars and display the block. ! $template->assign_vars( array( 'L_USES' => $lang['Uses'], ! 'L_RANK' => $lang['Rank'], ! 'L_PERCENTAGE' => $lang['Percent'], ! 'L_GRAPH' => $lang['Graph'], ! 'L_IMAGE' => $lang['Smile'], ! 'L_CODE' => $lang['smiley_code'], - 'TEXT_CLASS' => $ss_phpbb->text_class, - 'L_TITLE' => $lang['Top_Smilies'] ) - ); $template->pparse( 'body' ); ! ! ?> --- 166,201 ---- $percent_array = $ss_phpbb->do_percent_math( $all_smilies[0]['count'], $all_smilies[$i]['count'], $total_smilies ); ! $template->assign_block_vars( 'datarow', array( ! 'RANK' => $i + 1, ! 'CLASS' => ( !( $i + 1 % 2 ) ) ? $theme['td_class2'] : $theme['td_class1'], ! 'CODE' => $all_smilies[$i]['code'], ! 'USES' => $all_smilies[$i]['count'], ! 'PERCENTAGE' => $percent_array['percentage'], ! 'BAR' => $percent_array['bar_percent'], ! 'URL' => '<img src="' . PHPBB_URL . $board_config['smilies_path'] . '/' . $all_smilies[$i]['smile_url'] . '" alt="' . $all_smilies[$i]['smile_url'] . '" border="0" />' ) ! ); } } + // // Setup voting bar images... ! // $ss_phpbb->set_voting_bar(); + // // Setup common template vars and display the block. + // + $template->assign_vars( array( + 'L_USES' => $lang['Uses'], + 'L_RANK' => $lang['Rank'], + 'L_PERCENTAGE' => $lang['Percent'], + 'L_GRAPH' => $lang['Graph'], + 'L_IMAGE' => $lang['Smile'], + 'L_CODE' => $lang['smiley_code'], ! 'TEXT_CLASS' => $ss_phpbb->text_class, ! 'L_TITLE' => $lang['Top_Smilies'] ) ! ); $template->pparse( 'body' ); ! ?> \ No newline at end of file Index: monthlytopics.php =================================================================== RCS file: /cvsroot/mxbb/mx_sitestats/monthlytopics.php,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** monthlytopics.php 5 Apr 2006 23:03:45 -0000 1.4 --- monthlytopics.php 29 Jun 2006 19:08:04 -0000 1.5 *************** *** 23,28 **** } // Include common module stuff... ! include_once( $module_root_path . 'includes/common.' . $phpEx ); --- 23,29 ---- } + // // Include common module stuff... ! // include_once( $module_root_path . 'includes/common.' . $phpEx ); *************** *** 36,58 **** $ss_phpbb = new sitestats_phpbb(); } // -------------------------------------------------------------------------------- // Block Procedure // -------------------------------------------------------------------------------- // This is the template used to render this block. ! $template->set_filenames( array( 'body' => 'sitestats_monthlystats_body.tpl' ) ! ); ! // Number of New Topics by Month ! $sql = 'SELECT YEAR(FROM_UNIXTIME(topic_time)) AS aar, MONTH(FROM_UNIXTIME(topic_time)) AS mnd, COUNT(*) AS ant FROM ' . TOPICS_TABLE . ' GROUP BY YEAR(FROM_UNIXTIME(topic_time)),MONTH(FROM_UNIXTIME(topic_time)) ORDER BY topic_time'; if ( !( $result = $db->sql_query( $sql ) ) ) { mx_message_die( GENERAL_ERROR, "Couldn't retrieve topics data", '', __LINE__, __FILE__, $sql ); } $topics_count = $db->sql_numrows( $result ); $topics_data = $db->sql_fetchrowset( $result ); --- 37,63 ---- $ss_phpbb = new sitestats_phpbb(); } + // -------------------------------------------------------------------------------- // Block Procedure // -------------------------------------------------------------------------------- + // // This is the template used to render this block. + // + $template->set_filenames( array( 'body' => 'sitestats_monthlystats_body.tpl' ) ); ! // // Number of New Topics by Month ! // $sql = 'SELECT YEAR(FROM_UNIXTIME(topic_time)) AS aar, MONTH(FROM_UNIXTIME(topic_time)) AS mnd, COUNT(*) AS ant FROM ' . TOPICS_TABLE . ' GROUP BY YEAR(FROM_UNIXTIME(topic_time)),MONTH(FROM_UNIXTIME(topic_time)) ORDER BY topic_time'; + if ( !( $result = $db->sql_query( $sql ) ) ) { mx_message_die( GENERAL_ERROR, "Couldn't retrieve topics data", '', __LINE__, __FILE__, $sql ); } + $topics_count = $db->sql_numrows( $result ); $topics_data = $db->sql_fetchrowset( $result ); *************** *** 75,118 **** } } ! $template->assign_block_vars( 'datarow', array( 'CLASS' => ( !( $i + 1 % 2 ) ) ? $theme['td_class2'] : $theme['td_class1'], ! 'YEAR' => $year, ! 'M01' => $m[1], ! 'M02' => $m[2], ! 'M03' => $m[3], ! 'M04' => $m[4], ! 'M05' => $m[5], ! 'M06' => $m[6], ! 'M07' => $m[7], ! 'M08' => $m[8], ! 'M09' => $m[9], ! 'M10' => $m[10], ! 'M11' => $m[11], ! 'M12' => $m[12] ) ! ); } // Setup common template vars and display the block. ! $template->assign_vars( array( 'L_YEAR' => $lang['Year'], ! 'L_MONTH' => $lang['Month'], ! 'L_NUMBER' => $lang['Number'], ! 'L_JAN' => $lang['datetime']['Jan'], ! 'L_FEB' => $lang['datetime']['Feb'], ! 'L_MAR' => $lang['datetime']['Mar'], ! 'L_APR' => $lang['datetime']['Apr'], ! 'L_MAY' => $lang['datetime']['May'], ! 'L_JUN' => $lang['datetime']['Jun'], ! 'L_JUL' => $lang['datetime']['Jul'], ! 'L_AUG' => $lang['datetime']['Aug'], ! 'L_SEP' => $lang['datetime']['Sep'], ! 'L_OCT' => $lang['datetime']['Oct'], ! 'L_NOV' => $lang['datetime']['Nov'], ! 'L_DEC' => $lang['datetime']['Dec'], - 'TEXT_CLASS' => $ss_phpbb->text_class, - 'L_TITLE' => $lang['Monthly_Topics'] ) - ); $template->pparse( 'body' ); ! ! ?> --- 80,126 ---- } } ! $template->assign_block_vars( 'datarow', array( ! 'CLASS' => ( !( $i + 1 % 2 ) ) ? $theme['td_class2'] : $theme['td_class1'], ! 'YEAR' => $year, ! 'M01' => $m[1], ! 'M02' => $m[2], ! 'M03' => $m[3], ! 'M04' => $m[4], ! 'M05' => $m[5], ! 'M06' => $m[6], ! 'M07' => $m[7], ! 'M08' => $m[8], ! 'M09' => $m[9], ! 'M10' => $m[10], ! 'M11' => $m[11], ! 'M12' => $m[12] ) ! ); } + // // Setup common template vars and display the block. + // + $template->assign_vars( array( + 'L_YEAR' => $lang['Year'], + 'L_MONTH' => $lang['Month'], + 'L_NUMBER' => $lang['Number'], ! 'L_JAN' => $lang['datetime']['Jan'], ! 'L_FEB' => $lang['datetime']['Feb'], ! 'L_MAR' => $lang['datetime']['Mar'], ! 'L_APR' => $lang['datetime']['Apr'], ! 'L_MAY' => $lang['datetime']['May'], ! 'L_JUN' => $lang['datetime']['Jun'], ! 'L_JUL' => $lang['datetime']['Jul'], ! 'L_AUG' => $lang['datetime']['Aug'], ! 'L_SEP' => $lang['datetime']['Sep'], ! 'L_OCT' => $lang['datetime']['Oct'], ! 'L_NOV' => $lang['datetime']['Nov'], ! 'L_DEC' => $lang['datetime']['Dec'], ! 'TEXT_CLASS' => $ss_phpbb->text_class, ! 'L_TITLE' => $lang['Monthly_Topics'] ) ! ); $template->pparse( 'body' ); ! ?> \ No newline at end of file Index: topposters_tiny.php =================================================================== RCS file: /cvsroot/mxbb/mx_sitestats/topposters_tiny.php,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** topposters_tiny.php 5 Apr 2006 23:03:45 -0000 1.4 --- topposters_tiny.php 29 Jun 2006 19:08:04 -0000 1.5 *************** *** 22,27 **** } // Include common module stuff... ! include_once( $module_root_path . 'includes/common.' . $phpEx ); --- 22,28 ---- } + // // Include common module stuff... ! // include_once( $module_root_path . 'includes/common.' . $phpEx ); *************** *** 35,51 **** $ss_phpbb = new sitestats_phpbb(); } // -------------------------------------------------------------------------------- // Block Procedure // -------------------------------------------------------------------------------- // This is the template used to render this block. ! $template->set_filenames( array( 'body' => 'sitestats_topposters_tiny.tpl' ) ! ); ! // Top Posters ! $sql = 'SELECT user_id, username, user_posts FROM ' . USERS_TABLE . ' ! WHERE (user_id <> ' . ANONYMOUS . ') AND (user_posts > 0) ORDER BY user_posts DESC, username ASC LIMIT ' . $ss_phpbb->return_limit; --- 36,54 ---- $ss_phpbb = new sitestats_phpbb(); } + // -------------------------------------------------------------------------------- // Block Procedure // -------------------------------------------------------------------------------- + // // This is the template used to render this block. + // + $template->set_filenames( array( 'body' => 'sitestats_topposters_tiny.tpl' ) ); ! // // Top Posters ! // $sql = 'SELECT user_id, username, user_posts FROM ' . USERS_TABLE . ' ! WHERE (user_id <> ' . ANONYMOUS . ') AND (user_posts > 0) ORDER BY user_posts DESC, username ASC LIMIT ' . $ss_phpbb->return_limit; *************** *** 60,79 **** for ( $i = 0; $i < $user_count; $i++ ) { ! $template->assign_block_vars( 'datarow', array( 'CLASS' => ( !( $i + 1 % 2 ) ) ? $theme['td_class2'] : $theme['td_class1'], ! 'USERNAME' => $user_data[$i]['username'], ! 'URL' => append_sid( PHPBB_URL . 'profile.php?mode=viewprofile&u=' . $user_data[$i]['user_id'] ), ! 'POSTS' => $user_data[$i]['user_posts'] ) ! ); } // Setup common template vars and display the block. ! $template->assign_vars( array( 'L_USERNAME' => $lang['Username'], ! 'L_POSTS' => $lang['Posts'], - 'TEXT_CLASS' => $ss_phpbb->text_class, - 'L_TITLE' => $lang['Top_Posters'] ) - ); $template->pparse( 'body' ); - ?> \ No newline at end of file --- 63,85 ---- for ( $i = 0; $i < $user_count; $i++ ) { ! $template->assign_block_vars( 'datarow', array( ! 'CLASS' => ( !( $i + 1 % 2 ) ) ? $theme['td_class2'] : $theme['td_class1'], ! 'USERNAME' => $user_data[$i]['username'], ! 'URL' => append_sid( PHPBB_URL . 'profile.php?mode=viewprofile&u=' . $user_data[$i]['user_id'] ), ! 'POSTS' => $user_data[$i]['user_posts'] ) ! ); } + // // Setup common template vars and display the block. + // + $template->assign_vars( array( + 'L_USERNAME' => $lang['Username'], + 'L_POSTS' => $lang['Posts'], ! 'TEXT_CLASS' => $ss_phpbb->text_class, ! 'L_TITLE' => $lang['Top_Posters'] ) ! ); $template->pparse( 'body' ); ?> \ No newline at end of file Index: fastestusers.php =================================================================== RCS file: /cvsroot/mxbb/mx_sitestats/fastestusers.php,v retrieving revision 1.5 retrieving revision 1.6 diff -C2 -d -r1.5 -r1.6 *** fastestusers.php 2 May 2006 23:29:13 -0000 1.5 --- fastestusers.php 29 Jun 2006 19:08:04 -0000 1.6 *************** *** 23,28 **** } // Include common module stuff... ! include_once( $module_root_path . 'includes/common.' . $phpEx ); --- 23,29 ---- } + // // Include common module stuff... ! // include_once( $module_root_path . 'includes/common.' . $phpEx ); *************** *** 40,50 **** // -------------------------------------------------------------------------------- // This is the template used to render this block. ! $template->set_filenames( array( 'body' => 'sitestats_fastestusers_body.tpl' ) ! ); ! // Fastest Users ! $currect_time = time(); $sql = "SELECT user_id, username, user_posts, user_regdate, --- 41,52 ---- // -------------------------------------------------------------------------------- + // // This is the template used to render this block. + // + $template->set_filenames( array( 'body' => 'sitestats_fastestusers_body.tpl' ) ); ! // // Fastest Users ! // $currect_time = time(); $sql = "SELECT user_id, username, user_posts, user_regdate, *************** *** 55,62 **** --- 57,66 ---- ORDER BY rate DESC LIMIT " . $ss_phpbb->return_limit; + if ( !( $result = $db->sql_query( $sql ) ) ) { mx_message_die( GENERAL_ERROR, "Couldn't retrieve users data", '', __LINE__, __FILE__, $sql ); } + $user_count = $db->sql_numrows( $result ); $user_data = $db->sql_fetchrowset( $result ); *************** *** 68,98 **** for( $i = 0; $i < $user_count; $i++ ) { ! $template->assign_block_vars( 'datarow', array( 'RANK' => $i + 1, ! 'CLASS' => ( !( $i + 1 % 2 ) ) ? $theme['td_class2'] : $theme['td_class1'], ! 'USERNAME' => $user_data[$i]['username'], ! 'PERCENTAGE' => number_format( $user_data[$i]['rate'], 2 ), ! 'BAR' => round( $user_data[$i]['rate'] * $cst ), ! 'URL' => append_sid( PHPBB_URL . 'profile.php?mode=viewprofile&u=' . $user_data[$i]['user_id'] ), ! 'RATE' => round( $user_data[$i]['rate'], 2 ), ! 'TIME' => $user_data[$i]['time_on_forum'] ) ! ); } // Setup voting bar images... ! $ss_phpbb->set_voting_bar(); // Setup common template vars and display the block. ! $template->assign_vars( array( 'L_RANK' => $lang['Rank'], ! 'L_TIME' => $lang['time_on_forum'], ! 'L_POST_PER_DAY' => $lang['posts_day'], ! 'L_GRAPH' => $lang['Graph'], ! 'L_USERNAME' => $lang['Username'], - 'TEXT_CLASS' => $ss_phpbb->text_class, - 'L_TITLE' => $lang['Fastest_Users'] ) - ); $template->pparse( 'body' ); ! ! ?> --- 72,106 ---- for( $i = 0; $i < $user_count; $i++ ) { ! $template->assign_block_vars( 'datarow', array( ! 'RANK' => $i + 1, ! 'CLASS' => ( !( $i + 1 % 2 ) ) ? $theme['td_class2'] : $theme['td_class1'], ! 'USERNAME' => $user_data[$i]['username'], ! 'PERCENTAGE' => number_format( $user_data[$i]['rate'], 2 ), ! 'BAR' => round( $user_data[$i]['rate'] * $cst ), ! 'URL' => append_sid( PHPBB_URL . 'profile.php?mode=viewprofile&u=' . $user_data[$i]['user_id'] ), ! 'RATE' => round( $user_data[$i]['rate'], 2 ), ! 'TIME' => $user_data[$i]['time_on_forum'] ) ! ); } + // // Setup voting bar images... ! // $ss_phpbb->set_voting_bar(); + // // Setup common template vars and display the block. + // + $template->assign_vars( array( + 'L_RANK' => $lang['Rank'], + 'L_TIME' => $lang['time_on_forum'], + 'L_POST_PER_DAY' => $lang['posts_day'], + 'L_GRAPH' => $lang['Graph'], + 'L_USERNAME' => $lang['Username'], ! 'TEXT_CLASS' => $ss_phpbb->text_class, ! 'L_TITLE' => $lang['Fastest_Users'] ) ! ); $template->pparse( 'body' ); ! ?> \ No newline at end of file Index: topposters.php =================================================================== RCS file: /cvsroot/mxbb/mx_sitestats/topposters.php,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** topposters.php 5 Apr 2006 23:03:45 -0000 1.4 --- topposters.php 29 Jun 2006 19:08:04 -0000 1.5 *************** *** 23,28 **** } // Include common module stuff... ! include_once( $module_root_path . 'includes/common.' . $phpEx ); --- 23,29 ---- } + // // Include common module stuff... ! // include_once( $module_root_path . 'includes/common.' . $phpEx ); *************** *** 36,54 **** $ss_phpbb = new sitestats_phpbb(); } // -------------------------------------------------------------------------------- // Block Procedure // -------------------------------------------------------------------------------- // This is the template used to render this block. ! $template->set_filenames( array( 'body' => 'sitestats_topposters_body.tpl' ) ! ); ! // Top Posters ! $sql = 'SELECT user_id, username, user_posts FROM ' . USERS_TABLE . ' ! WHERE (user_id <> ' . ANONYMOUS . ') AND (user_posts > 0) ORDER BY user_posts DESC LIMIT ' . $ss_phpbb->return_limit; if ( !( $result = $db->sql_query( $sql ) ) ) { --- 37,58 ---- $ss_phpbb = new sitestats_phpbb(); } + // -------------------------------------------------------------------------------- // Block Procedure // -------------------------------------------------------------------------------- + // // This is the template used to render this block. + // + $template->set_filenames( array( 'body' => 'sitestats_topposters_body.tpl' ) ); ! // // Top Posters ! // $sql = 'SELECT user_id, username, user_posts FROM ' . USERS_TABLE . ' ! WHERE (user_id <> ' . ANONYMOUS . ') AND (user_posts > 0) ORDER BY user_posts DESC LIMIT ' . $ss_phpbb->return_limit; + if ( !( $result = $db->sql_query( $sql ) ) ) { *************** *** 65,94 **** $percent_array = $ss_phpbb->do_percent_math( $firstcount, $user_data[$i]['user_posts'], $total_posts ); ! $template->assign_block_vars( 'datarow', array( 'RANK' => $i + 1, ! 'CLASS' => ( !( $i + 1 % 2 ) ) ? $theme['td_class2'] : $theme['td_class1'], ! 'USERNAME' => $user_data[$i]['username'], ! 'PERCENTAGE' => $percent_array['percentage'], ! 'BAR' => $percent_array['bar_percent'], ! 'URL' => append_sid( PHPBB_URL . 'profile.php?mode=viewprofile&u=' . $user_data[$i]['user_id'] ), ! 'POSTS' => $user_data[$i]['user_posts'] ) ! ); } // Setup voting bar images... ! $ss_phpbb->set_voting_bar(); // Setup common template vars and display the block. ! $template->assign_vars( array( 'L_POSTS' => $lang['Posts'], ! 'L_RANK' => $lang['Rank'], ! 'L_PERCENTAGE' => $lang['Percent'], ! 'L_GRAPH' => $lang['Graph'], ! 'L_USERNAME' => $lang['Username'], - 'TEXT_CLASS' => $ss_phpbb->text_class, - 'L_TITLE' => $lang['Top_Posters'] ) - ); $template->pparse( 'body' ); ! ! ?> --- 69,102 ---- $percent_array = $ss_phpbb->do_percent_math( $firstcount, $user_data[$i]['user_posts'], $total_posts ); ! $template->assign_block_vars( 'datarow', array( ! 'RANK' => $i + 1, ! 'CLASS' => ( !( $i + 1 % 2 ) ) ? $theme['td_class2'] : $theme['td_class1'], ! 'USERNAME' => $user_data[$i]['username'], ! 'PERCENTAGE' => $percent_array['percentage'], ! 'BAR' => $percent_array['bar_percent'], ! 'URL' => append_sid( PHPBB_URL . 'profile.php?mode=viewprofile&u=' . $user_data[$i]['user_id'] ), ! 'POSTS' => $user_data[$i]['user_posts'] ) ! ); } + // // Setup voting bar images... ! // $ss_phpbb->set_voting_bar(); + // // Setup common template vars and display the block. + // + $template->assign_vars( array( + 'L_POSTS' => $lang['Posts'], + 'L_RANK' => $lang['Rank'], + 'L_PERCENTAGE' => $lang['Percent'], + 'L_GRAPH' => $lang['Graph'], + 'L_USERNAME' => $lang['Username'], ! 'TEXT_CLASS' => $ss_phpbb->text_class, ! 'L_TITLE' => $lang['Top_Posters'] ) ! ); $template->pparse( 'body' ); ! ?> \ No newline at end of file Index: sitestaff.php =================================================================== RCS file: /cvsroot/mxbb/mx_sitestats/sitestaff.php,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** sitestaff.php 5 Apr 2006 23:03:45 -0000 1.4 --- sitestaff.php 29 Jun 2006 19:08:04 -0000 1.5 *************** *** 23,28 **** } // Include common module stuff... ! include_once( $module_root_path . 'includes/common.' . $phpEx ); --- 23,29 ---- } + // // Include common module stuff... ! // include_once( $module_root_path . 'includes/common.' . $phpEx ); *************** *** 36,39 **** --- 37,41 ---- $ss_phpbb = new sitestats_phpbb(); } + // -------------------------------------------------------------------------------- // Block Procedure *************** *** 42,50 **** // This is the template used to render this block. ! $template->set_filenames( array( 'body' => 'sitestats_sitestaff_body.tpl' ) ! ); // forums ! $sql = "SELECT ug.user_id, f.forum_id, f.forum_name FROM " . AUTH_ACCESS_TABLE . " aa, " . USER_GROUP_TABLE . " ug, " . FORUMS_TABLE . " f --- 44,52 ---- // This is the template used to render this block. ! $template->set_filenames( array( 'body' => 'sitestats_sitestaff_body.tpl' ) ); + // // forums ! // $sql = "SELECT ug.user_id, f.forum_id, f.forum_name FROM " . AUTH_ACCESS_TABLE . " aa, " . USER_GROUP_TABLE . " ug, " . FORUMS_TABLE . " f *************** *** 52,59 **** --- 54,63 ---- AND ug.group_id = aa.group_id AND f.forum_id = aa.forum_id"; + if ( !$result = $db->sql_query( $sql ) ) { mx_message_die( GENERAL_ERROR, "Couldn't query forums.", '', __LINE__, __FILE__, $sql ); } + while ( $row = $db->sql_fetchrow( $result ) ) { *************** *** 62,67 **** } // main ! $sql = "SELECT * FROM " . USERS_TABLE . " WHERE user_level >= 1 --- 66,72 ---- } + // // main ! // $sql = "SELECT * FROM " . USERS_TABLE . " WHERE user_level >= 1 *************** *** 177,218 **** } ! $template->assign_block_vars( 'staff', array( 'AVATAR' => $avatar, ! 'RANK' => $rank, ! 'RANK_IMAGE' => $rank_image, ! 'U_NAME' => append_sid( PHPBB_URL . "profile.$phpEx?mode=viewprofile&" . POST_USERS_URL . "=$staff[user_id]" ), ! 'NAME' => $staff[username], ! 'LEVEL' => $level, ! 'FORUMS' => $forums, ! 'JOINED' => create_date( $board_config['default_dateformat'], $staff['user_regdate'], $board_config['board_timezone'] ), ! 'PERIOD' => sprintf( $lang['SiteStats_Staff_Period'], $memberdays ), ! 'POSTS' => $staff['user_posts'], ! 'POST_DAY' => sprintf( $lang['User_post_day_stats'], $posts_per_day ), ! 'POST_PERCENT' => sprintf( $lang['User_post_pct_stats'], $percentage ), ! 'LAST_POST' => $last_post, ! 'MAIL' => $mail, ! 'PM' => $pm, ! 'MSN' => $msn, ! 'YIM' => $yim, ! 'AIM' => $aim, ! 'ICQ' => $icq, ! 'WWW' => $www ) ! ); } // Setup common template vars and display the block. - $template->assign_vars( array( 'L_AVATAR' => $lang['Avatar'], - 'L_USERNAME' => $lang['Username'], - 'L_POSTS' => $lang['Posts'], - 'L_JOINED' => $lang['Joined'], - 'L_EMAIL' => $lang['Email'], - 'L_PM' => $lang['Private_Message'], - 'L_WWW' => $lang['Website'], - 'L_CONTACT' => $lang['Contact'], - 'L_FORUMS' => $lang['SiteStats_Staff_Forums'], - 'L_MESSENGER' => $lang['SiteStats_Staff_Messenger'], - 'L_TITLE' => $lang['SiteStats_Staff'] ) - ); $template->pparse( 'body' ); ! ! ?> --- 182,226 ---- } ! $template->assign_block_vars( 'staff', array( ! 'AVATAR' => $avatar, ! 'RANK' => $rank, ! 'RANK_IMAGE' => $rank_image, ! 'U_NAME' => append_sid( PHPBB_URL . "profile.$phpEx?mode=viewprofile&" . POST_USERS_URL . "=$staff[user_id]" ), ! 'NAME' => $staff[username], ! 'LEVEL' => $level, ! 'FORUMS' => $forums, ! 'JOINED' => create_date( $board_config['default_dateformat'], $staff['user_regdate'], $board_config['board_timezone'] ), ! 'PERIOD' => sprintf( $lang['SiteStats_Staff_Period'], $memberdays ), ! 'POSTS' => $staff['user_posts'], ! 'POST_DAY' => sprintf( $lang['User_post_day_stats'], $posts_per_day ), ! 'POST_PERCENT' => sprintf( $lang['User_post_pct_stats'], $percentage ), ! 'LAST_POST' => $last_post, ! 'MAIL' => $mail, ! 'PM' => $pm, ! 'MSN' => $msn, ! 'YIM' => $yim, ! 'AIM' => $aim, ! 'ICQ' => $icq, ! 'WWW' => $www ) ! ); } + // // Setup common template vars and display the block. + // + $template->assign_vars( array( + 'L_AVATAR' => $lang['Avatar'], + 'L_USERNAME' => $lang['Username'], + 'L_POSTS' => $lang['Posts'], + 'L_JOINED' => $lang['Joined'], + 'L_EMAIL' => $lang['Email'], + 'L_PM' => $lang['Private_Message'], + 'L_WWW' => $lang['Website'], + 'L_CONTACT' => $lang['Contact'], + 'L_FORUMS' => $lang['SiteStats_Staff_Forums'], + 'L_MESSENGER' => $lang['SiteStats_Staff_Messenger'], + 'L_TITLE' => $lang['SiteStats_Staff'] ) + ); $template->pparse( 'body' ); ! ?> \ No newline at end of file Index: monthlyposts.php =================================================================== RCS file: /cvsroot/mxbb/mx_sitestats/monthlyposts.php,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** monthlyposts.php 5 Apr 2006 23:03:45 -0000 1.4 --- monthlyposts.php 29 Jun 2006 19:08:04 -0000 1.5 *************** *** 23,28 **** } // Include common module stuff... ! include_once( $module_root_path . 'includes/common.' . $phpEx ); --- 23,29 ---- } + // // Include common module stuff... ! // include_once( $module_root_path . 'includes/common.' . $phpEx ); *************** *** 36,58 **** $ss_phpbb = new sitestats_phpbb(); } // -------------------------------------------------------------------------------- // Block Procedure // -------------------------------------------------------------------------------- // This is the template used to render this block. ! $template->set_filenames( array( 'body' => 'sitestats_monthlystats_body.tpl' ) ! ); ! // Number of New Posts by Month ! $sql = 'SELECT YEAR(FROM_UNIXTIME(post_time)) AS aar, MONTH(FROM_UNIXTIME(post_time)) AS mnd, COUNT(*) AS ant FROM ' . POSTS_TABLE . ' GROUP BY YEAR(FROM_UNIXTIME(post_time)),MONTH(FROM_UNIXTIME(post_time)) ORDER BY post_time'; if ( !( $result = $db->sql_query( $sql ) ) ) { mx_message_die( GENERAL_ERROR, "Couldn't retrieve posts data", '', __LINE__, __FILE__, $sql ); } $posts_count = $db->sql_numrows( $result ); $posts_data = $db->sql_fetchrowset( $result ); --- 37,63 ---- $ss_phpbb = new sitestats_phpbb(); } + // -------------------------------------------------------------------------------- // Block Procedure // -------------------------------------------------------------------------------- + // // This is the template used to render this block. + // + $template->set_filenames( array( 'body' => 'sitestats_monthlystats_body.tpl' ) ); ! // // Number of New Posts by Month ! // $sql = 'SELECT YEAR(FROM_UNIXTIME(post_time)) AS aar, MONTH(FROM_UNIXTIME(post_time)) AS mnd, COUNT(*) AS ant FROM ' . POSTS_TABLE . ' GROUP BY YEAR(FROM_UNIXTIME(post_time)),MONTH(FROM_UNIXTIME(post_time)) ORDER BY post_time'; + if ( !( $result = $db->sql_query( $sql ) ) ) { mx_message_die( GENERAL_ERROR, "Couldn't retrieve posts data", '', __LINE__, __FILE__, $sql ); } + $posts_count = $db->sql_numrows( $result ); $posts_data = $db->sql_fetchrowset( $result ); *************** *** 88,118 **** 'M10' => $m[10], 'M11' => $m[11], ! 'M12' => $m[12] ) ); } // Setup common template vars and display the block. ! $template->assign_vars( array( 'L_YEAR' => $lang['Year'], ! 'L_MONTH' => $lang['Month'], ! 'L_NUMBER' => $lang['Number'], ! 'L_JAN' => $lang['datetime']['Jan'], ! 'L_FEB' => $lang['datetime']['Feb'], ! 'L_MAR' => $lang['datetime']['Mar'], ! 'L_APR' => $lang['datetime']['Apr'], ! 'L_MAY' => $lang['datetime']['May'], ! 'L_JUN' => $lang['datetime']['Jun'], ! 'L_JUL' => $lang['datetime']['Jul'], ! 'L_AUG' => $lang['datetime']['Aug'], ! 'L_SEP' => $lang['datetime']['Sep'], ! 'L_OCT' => $lang['datetime']['Oct'], ! 'L_NOV' => $lang['datetime']['Nov'], ! 'L_DEC' => $lang['datetime']['Dec'], - 'TEXT_CLASS' => $ss_phpbb->text_class, - 'L_TITLE' => $lang['Monthly_Posts'] ) - ); $template->pparse( 'body' ); ! ! ?> --- 93,125 ---- 'M10' => $m[10], 'M11' => $m[11], ! 'M12' => $m[12] ) ); } + // // Setup common template vars and display the block. + // + $template->assign_vars( array( + 'L_YEAR' => $lang['Year'], + 'L_MONTH' => $lang['Month'], + 'L_NUMBER' => $lang['Number'], ! 'L_JAN' => $lang['datetime']['Jan'], ! 'L_FEB' => $lang['datetime']['Feb'], ! 'L_MAR' => $lang['datetime']['Mar'], ! 'L_APR' => $lang['datetime']['Apr'], ! 'L_MAY' => $lang['datetime']['May'], ! 'L_JUN' => $lang['datetime']['Jun'], ! 'L_JUL' => $lang['datetime']['Jul'], ! 'L_AUG' => $lang['datetime']['Aug'], ! 'L_SEP' => $lang['datetime']['Sep'], ! 'L_OCT' => $lang['datetime']['Oct'], ! 'L_NOV' => $lang['datetime']['Nov'], ! 'L_DEC' => $lang['datetime']['Dec'], ! 'TEXT_CLASS' => $ss_phpbb->text_class, ! 'L_TITLE' => $lang['Monthly_Posts'] ) ! ); $template->pparse( 'body' ); ! ?> \ No newline at end of file Index: adminstats.php =================================================================== RCS file: /cvsroot/mxbb/mx_sitestats/adminstats.php,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** adminstats.php 5 Apr 2006 23:03:45 -0000 1.4 --- adminstats.php 29 Jun 2006 19:08:03 -0000 1.5 *************** *** 23,28 **** } // Include common module stuff... ! include_once( $module_root_path . 'includes/common.' . $phpEx ); --- 23,29 ---- } + // // Include common module stuff... ! // include_once( $module_root_path . 'includes/common.' . $phpEx ); *************** *** 37,42 **** } // Load language files, required for several Administrative Statistics... ! if ( file_exists( $phpbb_root_path . 'language/lang_' . $board_config['default_lang'] . '/lang_admin.' . $phpEx ) ) { --- 38,44 ---- } + // // Load language files, required for several Administrative Statistics... ! // if ( file_exists( $phpbb_root_path . 'language/lang_' . $board_config['default_lang'] . '/lang_admin.' . $phpEx ) ) { *************** *** 47,50 **** --- 49,53 ---- include_once( $phpbb_root_path . 'language/lang_english/lang_admin.' . $phpEx ); } + // -------------------------------------------------------------------------------- // Block Procedure *************** *** 53,61 **** // This is the template used to render this block. ! $template->set_filenames( array( 'body' => 'sitestats_adminstats_body.tpl' ) ! ); // Administrative Statistics ! $attachment_mod_installed = ( defined( 'ATTACH_VERSION' ) ) ? true : false; $attachment_version = ( $attachment_mod_installed ) ? ATTACH_VERSION : ''; --- 56,64 ---- // This is the template used to render this block. ! $template->set_filenames( array( 'body' => 'sitestats_adminstats_body.tpl' ) ); + // // Administrative Statistics ! // $attachment_mod_installed = ( defined( 'ATTACH_VERSION' ) ) ? true : false; $attachment_version = ( $attachment_mod_installed ) ? ATTACH_VERSION : ''; *************** *** 89,98 **** } } ! @closedir( $avatar_dir ); ! // This bit of code translates the avatar directory size into human readable format // Borrowed the code from the PHP.net annoted manual, origanally written by: // Jesse (je...@je...) ! if ( !$attachment_mod_installed ) { --- 92,101 ---- } } ! @closedir( $avatar_dir ); ! // This bit of code translates the avatar directory size into human readable format // Borrowed the code from the PHP.net annoted manual, origanally written by: // Jesse (je...@je...) ! if ( !$attachment_mod_installed ) { *************** *** 235,239 **** $newest_uid = $newest_userdata['user_id']; ! $sql = 'SELECT user_regdate FROM ' . USERS_TABLE . ' WHERE user_id = ' . $newest_uid . ' LIMIT 1'; if ( !( $result = $db->sql_query( $sql ) ) ) --- 238,242 ---- $newest_uid = $newest_userdata['user_id']; ! $sql = 'SELECT user_regdate FROM ' . USERS_TABLE . ' WHERE user_id = ' . $newest_uid . ' LIMIT 1'; if ( !( $result = $db->sql_query( $sql ) ) ) *************** *** 244,249 **** $newest_user_date = $row['user_regdate']; // Most Online data ! $sql = "SELECT * FROM " . CONFIG_TABLE . " WHERE config_name = 'record_online_users' OR config_name = 'record_online_date'"; --- 247,253 ---- $newest_user_date = $row['user_regdate']; + // // Most Online data ! // $sql = "SELECT * FROM " . CONFIG_TABLE . " WHERE config_name = 'record_online_users' OR config_name = 'record_online_date'"; *************** *** 282,287 **** $lang['Most_Ever_Online_Date'], $lang['Most_Ever_Online'], ! $lang['Gzip_compression'] ! ); $value_array = array( $total_posts, $posts_per_day, --- 286,292 ---- $lang['Most_Ever_Online_Date'], $lang['Most_Ever_Online'], ! $lang['Gzip_compression'] ! ); ! $value_array = array( $total_posts, $posts_per_day, *************** *** 300,308 **** $most_users_date, $most_users, ! ( $board_config['gzip_compress'] ) ? $lang['Enabled'] : $lang['Disabled'] ! ); // Disk Usage, if Attachment Mod is installed ! if ( $attachment_mod_installed ) { --- 305,314 ---- $most_users_date, $most_users, ! ( $board_config['gzip_compress'] ) ? $lang['Enabled'] : $lang['Disabled'] ! ); + // // Disk Usage, if Attachment Mod is installed ! // if ( $attachment_mod_installed ) { *************** *** 317,333 **** 'VALUE' => $value_array[$i], 'STATISTIC2' => ( isset( $statistic_array[$i + 1] ) ) ? $statistic_array[$i + 1] : '', ! 'VALUE2' => ( isset( $value_array[$i + 1] ) ) ? $value_array[$i + 1] : '' ) ); } // Setup common template vars and display the block. ! $template->assign_vars( array( 'L_STATISTIC' => $lang['Statistic'], ! 'L_VALUE' => $lang['Value'], ! ! 'TEXT_CLASS' => $ss_phpbb->text_class, ! 'L_TITLE' => $lang['Admin_Stats'] ) ! ); $template->pparse( 'body' ); ! ! ?> --- 323,340 ---- 'VALUE' => $value_array[$i], 'STATISTIC2' => ( isset( $statistic_array[$i + 1] ) ) ? $statistic_array[$i + 1] : '', ! 'VALUE2' => ( isset( $value_array[$i + 1] ) ) ? $value_array[$i + 1] : '' ) ); } + // // Setup common template vars and display the block. + // + $template->assign_vars( array( + 'L_STATISTIC' => $lang['Statistic'], + 'L_VALUE' => $lang['Value'], ! 'TEXT_CLASS' => $ss_phpbb->text_class, ! 'L_TITLE' => $lang['Admin_Stats'] ) ! ); $template->pparse( 'body' ); ! ?> \ No newline at end of file Index: topreferers.php =================================================================== RCS file: /cvsroot/mxbb/mx_sitestats/topreferers.php,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** topreferers.php 5 Apr 2006 23:03:45 -0000 1.4 --- topreferers.php 29 Jun 2006 19:08:04 -0000 1.5 *************** *** 22,27 **** } // Include common module stuff... ! include_once( $module_root_path . 'includes/common.' . $phpEx ); --- 22,28 ---- } + // // Include common module stuff... ! // include_once( $module_root_path . 'includes/common.' . $phpEx ); *************** *** 35,51 **** // -------------------------------------------------------------------------------- // This is the template used to render this block. ! $template-... [truncated message content] |
|
From: Jon O. <jon...@us...> - 2006-06-29 19:08:09
|
Update of /cvsroot/mxbb/mx_sitestats/admin In directory sc8-pr-cvs7.sourceforge.net:/tmp/cvs-serv19996/modules/mx_sitestats/admin Modified Files: admin_counter.php admin_referers.php admin_sitestats.php Log Message: code cleanup Index: admin_referers.php =================================================================== RCS file: /cvsroot/mxbb/mx_sitestats/admin/admin_referers.php,v retrieving revision 1.6 retrieving revision 1.7 diff -C2 -d -r1.6 -r1.7 *** admin_referers.php 2 May 2006 23:29:13 -0000 1.6 --- admin_referers.php 29 Jun 2006 19:08:03 -0000 1.7 *************** *** 13,18 **** // ====================================================== // This is how we add an entry to the phpBB Administration Control Panel... ! if ( !empty( $setmodules ) ) { --- 13,19 ---- // ====================================================== + // // This is how we add an entry to the phpBB Administration Control Panel... ! // if ( !empty( $setmodules ) ) { *************** *** 21,45 **** } // Setup basic portal stuff... ! define( 'IN_PORTAL', 1 ); $mx_root_path = '../../../'; $module_root_path = '../'; // Security and page header... ! $phpEx = substr(strrchr(__FILE__, '.'), 1); $no_page_header = true; require( $mx_root_path . 'admin/pagestart.' . $phpEx ); // Include common module stuff... ! require( $module_root_path . 'includes/common.' . $phpEx ); // ====================================================== // [ MAIN PROCESS ] // ====================================================== - // Get POST/GET variables... ! $start = intval( ( isset( $_POST['start'] ) ) ? $_POST['start'] : ( ( isset( $_GET['start'] ) ) ? $_GET['start'] : 0 ) ); $sort_method = ( ( isset( $_POST['sort'] ) ) ? $_POST['sort'] : ( ( isset( $_GET['sort'] ) ) ? $_GET['sort'] : 'hits' ) ); --- 22,49 ---- } + // // Setup basic portal stuff... ! // define( 'IN_PORTAL', 1 ); $mx_root_path = '../../../'; $module_root_path = '../'; + // // Security and page header... ! // $phpEx = substr(strrchr(__FILE__, '.'), 1); $no_page_header = true; require( $mx_root_path . 'admin/pagestart.' . $phpEx ); + // // Include common module stuff... ! // require( $module_root_path . 'includes/common.' . $phpEx ); + // ====================================================== // [ MAIN PROCESS ] // ====================================================== // Get POST/GET variables... ! // $start = intval( ( isset( $_POST['start'] ) ) ? $_POST['start'] : ( ( isset( $_GET['start'] ) ) ? $_GET['start'] : 0 ) ); $sort_method = ( ( isset( $_POST['sort'] ) ) ? $_POST['sort'] : ( ( isset( $_GET['sort'] ) ) ? $_GET['sort'] : 'hits' ) ); *************** *** 52,57 **** $id_list = ( !empty( $_POST['id_list'] ) ) ? $_POST['id_list'] : array(); // Check which mode we should operate in... ! if ( $enable ) { --- 56,62 ---- $id_list = ( !empty( $_POST['id_list'] ) ) ? $_POST['id_list'] : array(); + // // Check which mode we should operate in... ! // if ( $enable ) { *************** *** 87,92 **** // [ DEFAULT PROCESS ] // ====================================================== - // Get TopReferers Block Settings... $sql = "SELECT block_id FROM " . BLOCK_TABLE . " WHERE block_title = 'Top_Referers' LIMIT 1"; if ( !$result = $db->sql_query( $sql ) ) --- 92,97 ---- // [ DEFAULT PROCESS ] // ====================================================== // Get TopReferers Block Settings... + // $sql = "SELECT block_id FROM " . BLOCK_TABLE . " WHERE block_title = 'Top_Referers' LIMIT 1"; if ( !$result = $db->sql_query( $sql ) ) *************** *** 109,119 **** $rows_per_page *= 2; // Setup report variables... ! ! $a_sort_method = array( 'host' => $lang['Host'], 'hits' => $lang['Hits'], 'firstvisit' => $lang['First_visit'], 'lastvisit' => $lang['Last_visit'] ! ); $s_sort_method = ''; foreach( $a_sort_method as $s_value => $s_text ) --- 114,127 ---- $rows_per_page *= 2; + // // Setup report variables... ! // ! $a_sort_method = array( ! 'host' => $lang['Host'], 'hits' => $lang['Hits'], 'firstvisit' => $lang['First_visit'], 'lastvisit' => $lang['Last_visit'] ! ); ! $s_sort_method = ''; foreach( $a_sort_method as $s_value => $s_text ) *************** *** 123,136 **** } // Get total records count, for pagination... ! $total_rows = array(); $sql = 'SELECT COUNT(*) AS total FROM ' . SITESTATS_REFERER_TABLE . ' WHERE enabled = 0'; if ( !$result = $db->sql_query( $sql ) ) { mx_message_die( GENERAL_ERROR, "Couldn't query HTTP Referers Count", '', __LINE__, __FILE__, $sql ); } $row = $db->sql_fetchrow( $result ); $total_rows[0] = $row['total']; $sql = 'SELECT COUNT(*) AS total FROM ' . SITESTATS_REFERER_TABLE . ' WHERE enabled = 1'; if ( !$result = $db->sql_query( $sql ) ) --- 131,148 ---- } + // // Get total records count, for pagination... ! // $total_rows = array(); $sql = 'SELECT COUNT(*) AS total FROM ' . SITESTATS_REFERER_TABLE . ' WHERE enabled = 0'; + if ( !$result = $db->sql_query( $sql ) ) { mx_message_die( GENERAL_ERROR, "Couldn't query HTTP Referers Count", '', __LINE__, __FILE__, $sql ); } + $row = $db->sql_fetchrow( $result ); $total_rows[0] = $row['total']; + $sql = 'SELECT COUNT(*) AS total FROM ' . SITESTATS_REFERER_TABLE . ' WHERE enabled = 1'; if ( !$result = $db->sql_query( $sql ) ) *************** *** 138,147 **** mx_message_die( GENERAL_ERROR, "Couldn't query HTTP Referers Count", '', __LINE__, __FILE__, $sql ); } $row = $db->sql_fetchrow( $result ); $total_rows[1] = $row['total']; $total_now = ( $filter_flag == 'enabled' ) ? 1 : 0; // Default process is report... ! switch ( $sort_method ) { --- 150,161 ---- mx_message_die( GENERAL_ERROR, "Couldn't query HTTP Referers Count", '', __LINE__, __FILE__, $sql ); } + $row = $db->sql_fetchrow( $result ); $total_rows[1] = $row['total']; $total_now = ( $filter_flag == 'enabled' ) ? 1 : 0; + // // Default process is report... ! // switch ( $sort_method ) { *************** *** 160,163 **** --- 174,178 ---- break; } + $sql = 'SELECT * FROM ' . SITESTATS_REFERER_TABLE . ' WHERE enabled = ' . ( ( $filter_flag == 'enabled' ) ? 1 : 0 ) . ' ORDER BY ' . $order_by . ' LIMIT ' . $start . ', ' . $rows_per_page; if ( !$result = $db->sql_query( $sql ) ) *************** *** 168,175 **** $rowset_count = count( $rowset ); // Set template variables and send to browser... ! ! $template->set_filenames( array( 'body' => 'admin/sitestats_referers_admin.tpl' ) ! ); if ( $rowset_count > 0 ) --- 183,190 ---- $rowset_count = count( $rowset ); + // // Set template variables and send to browser... ! // ! $template->set_filenames( array( 'body' => 'admin/sitestats_referers_admin.tpl' ) ); if ( $rowset_count > 0 ) *************** *** 177,187 **** for( $i = 0; $i < $rowset_count; $i++ ) { ! $template->assign_block_vars( 'datarow', array( 'ROW_CLASS' => ( !( $i % 2 ) ) ? $theme['td_class1'] : $theme['td_class2'], ! 'ID' => $rowset[$i]['id'], ! 'HOST' => $rowset[$i]['host'], ! 'HITS' => $rowset[$i]['hits'], ! 'FIRST_VISIT' => create_date( 'Y-m-d H:i:s', $rowset[$i]['firstvisit'], $board_config['board_timezone'] ), ! 'LAST_VISIT' => create_date( 'Y-m-d H:i:s', $rowset[$i]['lastvisit'], $board_config['board_timezone'] ) ) ! ); } $template->assign_block_vars( 'ok_referers_sw', array() ); --- 192,203 ---- for( $i = 0; $i < $rowset_count; $i++ ) { ! $template->assign_block_vars( ! 'datarow', array( 'ROW_CLASS' => ( !( $i % 2 ) ) ? $theme['td_class1'] : $theme['td_class2'], ! 'ID' => $rowset[$i]['id'], ! 'HOST' => $rowset[$i]['host'], ! 'HITS' => $rowset[$i]['hits'], ! 'FIRST_VISIT' => create_date( 'Y-m-d H:i:s', $rowset[$i]['firstvisit'], $board_config['board_timezone'] ), ! 'LAST_VISIT' => create_date( 'Y-m-d H:i:s', $rowset[$i]['lastvisit'], $board_config['board_timezone'] ) ) ! ); } $template->assign_block_vars( 'ok_referers_sw', array() ); *************** *** 191,231 **** $template->assign_block_vars( 'no_referers_sw', array() ); } ! $template->assign_vars( array( 'L_TITLE' => $lang['Referers_Management'], ! 'L_EXPLAIN' => $lang['Referers_Management_explain'] . $lang['Enabled'] . '(' . $total_rows[1] . '), ' . $lang['Disabled'] . '(' . $total_rows[0] . ')', ! 'U_FORM_ACTION' => append_sid( @basename( __FILE__ ) ), ! 'L_SELECT_FILTER' => $lang['Select_filter'], ! 'L_ENABLED' => $lang['Enabled'], ! 'L_DISABLED' => $lang['Disabled'], ! 'L_GO' => $lang['Go'], ! 'ENABLED_SELECTED' => ( $filter_flag == 'enabled' ) ? 'checked="checked"' : '', ! 'DISABLED_SELECTED' => ( $filter_flag != 'enabled' ) ? 'checked="checked"' : '', ! 'L_SELECT_SORT_METHOD' => $lang['Select_sort_method'], ! 'S_SORT_METHOD' => $s_sort_method, ! 'L_SORT' => $lang['Sort'], ! 'L_ORDER' => $lang['Order'], ! 'L_SORT_DESCENDING' => $lang['Sort_Descending'], ! 'L_SORT_ASCENDING' => $lang['Sort_Ascending'], ! 'ASC_SELECTED' => ( $sort_order != 'DESC' ) ? 'selected="selected"' : '', ! 'DESC_SELECTED' => ( $sort_order == 'DESC' ) ? 'selected="selected"' : '', ! 'L_REFERER_HOST' => $lang['Host'], ! 'L_REFERER_HITS' => $lang['Hits'], ! 'L_FIRST_VISIT' => $lang['First_visit'], ! 'L_LAST_VISIT' => $lang['Last_visit'], ! 'L_NO_REFERERS' => ( $filter_flag == 'enabled' ) ? $lang['No_Enabled_Referers'] : $lang['No_Disabled_Referers'], ! 'L_MARK' => $lang['Mark'], ! 'L_MARK_ALL' => $lang['Mark_all'], ! 'L_UNMARK_ALL' => $lang['Unmark_all'], ! 'L_ENABLE_MARKED' => ( $filter_flag == 'enabled' ) ? $lang['Disable_marked'] : $lang['Enable_marked'], ! 'L_DELETE_MARKED' => $lang['Delete_marked'], ! 'L_DELETE_ALL' => $lang['Delete_all'], ! 'L_NO_ITEMS_MARKED' => $lang['No_items_marked'], ! 'L_PLEASE_CONFIRM' => $lang['Please_confirm'], - 'PAGINATION' => generate_pagination( append_sid( @basename( __FILE__ ) . "?filter=$filter_flag&sort=$sort_method&order=$sort_order" ), $total_rows[$total_now], $rows_per_page, $start ), - 'PAGE_NUMBER' => sprintf( $lang['Page_of'], ( floor( $start / $rows_per_page ) + 1 ), ceil( $total_rows[$total_now] / $rows_per_page ) ) - ) // end array - ); include_once( $mx_root_path . 'admin/page_header_admin.' . $phpEx ); $template->pparse( 'body' ); --- 207,248 ---- $template->assign_block_vars( 'no_referers_sw', array() ); } ! $template->assign_vars( array( ! 'L_TITLE' => $lang['Referers_Management'], ! 'L_EXPLAIN' => $lang['Referers_Management_explain'] . $lang['Enabled'] . '(' . $total_rows[1] . '), ' . $lang['Disabled'] . '(' . $total_rows[0] . ')', ! 'U_FORM_ACTION' => append_sid( @basename( __FILE__ ) ), ! 'L_SELECT_FILTER' => $lang['Select_filter'], ! 'L_ENABLED' => $lang['Enabled'], ! 'L_DISABLED' => $lang['Disabled'], ! 'L_GO' => $lang['Go'], ! 'ENABLED_SELECTED' => ( $filter_flag == 'enabled' ) ? 'checked="checked"' : '', ! 'DISABLED_SELECTED' => ( $filter_flag != 'enabled' ) ? 'checked="checked"' : '', ! 'L_SELECT_SORT_METHOD' => $lang['Select_sort_method'], ! 'S_SORT_METHOD' => $s_sort_method, ! 'L_SORT' => $lang['Sort'], ! 'L_ORDER' => $lang['Order'], ! 'L_SORT_DESCENDING' => $lang['Sort_Descending'], ! 'L_SORT_ASCENDING' => $lang['Sort_Ascending'], ! 'ASC_SELECTED' => ( $sort_order != 'DESC' ) ? 'selected="selected"' : '', ! 'DESC_SELECTED' => ( $sort_order == 'DESC' ) ? 'selected="selected"' : '', ! 'L_REFERER_HOST' => $lang['Host'], ! 'L_REFERER_HITS' => $lang['Hits'], ! 'L_FIRST_VISIT' => $lang['First_visit'], ! 'L_LAST_VISIT' => $lang['Last_visit'], ! 'L_NO_REFERERS' => ( $filter_flag == 'enabled' ) ? $lang['No_Enabled_Referers'] : $lang['No_Disabled_Referers'], ! 'L_MARK' => $lang['Mark'], ! 'L_MARK_ALL' => $lang['Mark_all'], ! 'L_UNMARK_ALL' => $lang['Unmark_all'], ! 'L_ENABLE_MARKED' => ( $filter_flag == 'enabled' ) ? $lang['Disable_marked'] : $lang['Enable_marked'], ! 'L_DELETE_MARKED' => $lang['Delete_marked'], ! 'L_DELETE_ALL' => $lang['Delete_all'], ! 'L_NO_ITEMS_MARKED' => $lang['No_items_marked'], ! 'L_PLEASE_CONFIRM' => $lang['Please_confirm'], ! ! 'PAGINATION' => generate_pagination( append_sid( @basename( __FILE__ ) . "?filter=$filter_flag&sort=$sort_method&order=$sort_order" ), $total_rows[$total_now], $rows_per_page, $start ), ! 'PAGE_NUMBER' => sprintf( $lang['Page_of'], ( floor( $start / $rows_per_page ) + 1 ), ceil( $total_rows[$total_now] / $rows_per_page ) ) ! ) ); include_once( $mx_root_path . 'admin/page_header_admin.' . $phpEx ); $template->pparse( 'body' ); *************** *** 238,241 **** include_once( $mx_root_path . 'admin/page_footer_admin.' . $phpEx ); exit; - ?> \ No newline at end of file --- 255,257 ---- Index: admin_sitestats.php =================================================================== RCS file: /cvsroot/mxbb/mx_sitestats/admin/admin_sitestats.php,v retrieving revision 1.5 retrieving revision 1.6 diff -C2 -d -r1.5 -r1.6 *** admin_sitestats.php 2 May 2006 23:29:13 -0000 1.5 --- admin_sitestats.php 29 Jun 2006 19:08:03 -0000 1.6 *************** *** 13,18 **** // ====================================================== // Add our entry to the Administration Control Panel... ! if ( !empty( $setmodules ) ) { --- 13,19 ---- // ====================================================== + // // Add our entry to the Administration Control Panel... ! // if ( !empty( $setmodules ) ) { *************** *** 21,37 **** } // Setup basic portal stuff... ! define( 'IN_PORTAL', true ); $mx_root_path = '../../../'; $module_root_path = "../"; // Security and page header... ! $phpEx = substr(strrchr(__FILE__, '.'), 1); require( $mx_root_path . '/admin/pagestart.' . $phpEx ); // Include common module stuff... ! require( $module_root_path . 'includes/common.' . $phpEx ); $sitestats_counter = new sitestats_counter(); --- 22,41 ---- } + // // Setup basic portal stuff... ! // define( 'IN_PORTAL', true ); $mx_root_path = '../../../'; $module_root_path = "../"; + // // Security and page header... ! // $phpEx = substr(strrchr(__FILE__, '.'), 1); require( $mx_root_path . '/admin/pagestart.' . $phpEx ); + // // Include common module stuff... ! // require( $module_root_path . 'includes/common.' . $phpEx ); $sitestats_counter = new sitestats_counter(); *************** *** 39,51 **** $sitestats_digary = $sitestats_counter->getDigitStyles( $digits_path ); // Send page header... ! include_once( $mx_root_path . 'admin/page_header_admin.' . $phpEx ); // ====================================================== // [ MAIN PROCESS ] // ====================================================== - // Read the module settings... ! $sql = "SELECT * FROM " . SITESTATS_CONFIG_TABLE; if ( !$result = $db->sql_query( $sql ) ) --- 43,56 ---- $sitestats_digary = $sitestats_counter->getDigitStyles( $digits_path ); + // // Send page header... ! // include_once( $mx_root_path . 'admin/page_header_admin.' . $phpEx ); + // ====================================================== // [ MAIN PROCESS ] // ====================================================== // Read the module settings... ! // $sql = "SELECT * FROM " . SITESTATS_CONFIG_TABLE; if ( !$result = $db->sql_query( $sql ) ) *************** *** 70,75 **** } // If the form was submitted, display the update successful message... ! if ( isset( $HTTP_POST_VARS['submit'] ) ) { --- 75,81 ---- } + // // If the form was submitted, display the update successful message... ! // if ( isset( $HTTP_POST_VARS['submit'] ) ) { *************** *** 80,90 **** } // Prepare the Settings form... ! $template->set_filenames( array( 'body' => 'admin/sitestats_settings.tpl' ) ! ); ! // Counter Settings... ! $select_class_ary = array( 'cattitle', 'gen', 'genmed', 'gensmall', 'maintitle', 'postbody', 'topictitle' ); $select_text_class = ''; --- 86,97 ---- } + // // Prepare the Settings form... + // + $template->set_filenames( array( 'body' => 'admin/sitestats_settings.tpl' ) ); ! // // Counter Settings... ! // $select_class_ary = array( 'cattitle', 'gen', 'genmed', 'gensmall', 'maintitle', 'postbody', 'topictitle' ); $select_text_class = ''; *************** *** 137,142 **** $counters_toshow_sess = ( $new['counters_toshow'] == 2 ) ? 'checked="checked"' : ''; // Referers Settings... ! $referers_logging_off = ( !$new['referers_logging'] ) ? 'checked="checked"' : ''; $referers_logging_on = ( $new['referers_logging'] ) ? 'checked="checked"' : ''; --- 144,150 ---- $counters_toshow_sess = ( $new['counters_toshow'] == 2 ) ? 'checked="checked"' : ''; + // // Referers Settings... ! // $referers_logging_off = ( !$new['referers_logging'] ) ? 'checked="checked"' : ''; $referers_logging_on = ( $new['referers_logging'] ) ? 'checked="checked"' : ''; *************** *** 145,212 **** $referers_showdis_on = ( $new['referers_show_disabled'] ) ? 'checked="checked"' : ''; // Setup template vars and send the HTML... ! $template->assign_vars( array( 'S_ACTION' => append_sid( @basename( __FILE__ ) ), ! 'L_SITESTATS_SETTINGS' => $lang['SiteStats_Settings'], ! 'L_SITESTATS_SETTINGS_EXPLAIN' => $lang['SiteStats_Settings_explain'], ! ! 'DIGITS_PATH' => $digits_path, ! 'SAMPLE_DIGITS' => $sample_digits, ! 'SPACER' => $images['mx_spacer'], ! 'L_COUNTER_SETTINGS' => $lang['Counter_Settings'], ! 'L_COUNTER_TYPE' => $lang['SiteStats_Counter_Type'], ! 'L_COUNTER_TYPE_EXPLAIN' => $lang['SiteStats_Counter_Typeinfo'], ! 'SELECT_COUNTER_TYPE' => $select_counter_type, ! 'L_TEXT_CLASS' => $lang['SiteStats_Text_Class'], ! 'L_TEXT_CLASS_EXPLAIN' => $lang['SiteStats_Text_Classinfo'], ! 'SELECT_TEXT_CLASS' => $select_text_class, ! 'L_COUNTER_CLASS' => $lang['SiteStats_Counter_Class'], ! 'L_COUNTER_CLASS_EXPLAIN' => $lang['SiteStats_Counter_Classinfo'], ! 'SELECT_COUNTER_CLASS' => $select_counter_class, ! 'L_COUNTER_STYLE' => $lang['SiteStats_Counter_Style'], ! 'L_COUNTER_STYLE_EXPLAIN' => $lang['SiteStats_Counter_Styleinfo'], ! 'COUNTER_STYLE' => $new['counter_style'], ! 'L_COUNTER_SIZE' => $lang['SiteStats_Counter_Size'], ! 'L_COUNTER_SIZE_EXPLAIN' => $lang['SiteStats_Counter_Sizeinfo'], ! 'COUNTER_SIZE' => $new['counter_size'], ! 'L_COUNTER_TOSHOW' => $lang['SiteStats_Counter_ToShow'], ! 'L_COUNTER_TOSHOW_EXPLAIN' => $lang['SiteStats_Counter_ToShowinfo'], ! 'COUNTER_TOSHOW' => $new['counters_toshow'], ! 'COUNTER_TOSHOW_HITS' => $counters_toshow_hits, ! 'COUNTER_TOSHOW_SESS' => $counters_toshow_sess, ! 'COUNTER_TOSHOW_BOTH' => $counters_toshow_both, ! 'L_MORE_STATS_PAGE' => $lang['SiteStats_MoreStats_Page'], ! 'L_MORE_STATS_PAGE_EXPLAIN' => $lang['SiteStats_MoreStats_Pageinfo'], ! 'MORE_STATS_PAGE' => $new['more_stats_page'], ! 'L_REFERERS_SETTINGS' => $lang['Referers_Settings'], ! 'L_REFERERS_LOGGING' => $lang['Referers_Logging'], ! 'L_REFERERS_LOGGING_EXPLAIN' => $lang['Referers_Logginginfo'], ! 'REFERERS_LOGGING' => $new['referers_logging'], ! 'REFERERS_LOGGING_ON' => $referers_logging_on, ! 'REFERERS_LOGGING_OFF' => $referers_logging_off, ! 'L_REFERERS_COUNT' => $lang['SiteStats_TopReferers_Count'], ! 'L_REFERERS_COUNT_EXPLAIN' => $lang['SiteStats_TopReferers_Countinfo'], ! 'REFERERS_COUNT' => $new['referers_count'], ! 'L_REFERERS_SHOWDIS' => $lang['SiteStats_TopReferers_ShowDisabled'], ! 'L_REFERERS_SHOWDIS_EXPLAIN' => $lang['SiteStats_TopReferers_ShowDisabledinfo'], ! 'REFERERS_SHOWDIS' => $new['referers_show_disabled'], ! 'REFERERS_SHOWDIS_ON' => $referers_showdis_on, ! 'REFERERS_SHOWDIS_OFF' => $referers_showdis_off, ! 'L_HITS' => $lang['SiteStats_Counter_hits'], ! 'L_SESSIONS' => $lang['SiteStats_Counter_sess'], ! 'L_BOTH' => $lang['Both'], ! 'L_ON' => $lang['On'], ! 'L_OFF' => $lang['Off'], ! 'L_SUBMIT' => $lang['Submit'], ! 'L_RESET' => $lang['Reset'] ) ! ); $template->pparse( 'body' ); - include_once( $mx_root_path . 'admin/page_footer_admin.' . $phpEx ); - ?> \ No newline at end of file --- 153,220 ---- $referers_showdis_on = ( $new['referers_show_disabled'] ) ? 'checked="checked"' : ''; + // // Setup template vars and send the HTML... + // + $template->assign_vars( array( + 'S_ACTION' => append_sid( @basename( __FILE__ ) ), + 'L_SITESTATS_SETTINGS' => $lang['SiteStats_Settings'], + 'L_SITESTATS_SETTINGS_EXPLAIN' => $lang['SiteStats_Settings_explain'], ! 'DIGITS_PATH' => $digits_path, ! 'SAMPLE_DIGITS' => $sample_digits, ! 'SPACER' => $images['mx_spacer'], ! 'L_COUNTER_SETTINGS' => $lang['Counter_Settings'], ! 'L_COUNTER_TYPE' => $lang['SiteStats_Counter_Type'], ! 'L_COUNTER_TYPE_EXPLAIN' => $lang['SiteStats_Counter_Typeinfo'], ! 'SELECT_COUNTER_TYPE' => $select_counter_type, ! 'L_TEXT_CLASS' => $lang['SiteStats_Text_Class'], ! 'L_TEXT_CLASS_EXPLAIN' => $lang['SiteStats_Text_Classinfo'], ! 'SELECT_TEXT_CLASS' => $select_text_class, ! 'L_COUNTER_CLASS' => $lang['SiteStats_Counter_Class'], ! 'L_COUNTER_CLASS_EXPLAIN' => $lang['SiteStats_Counter_Classinfo'], ! 'SELECT_COUNTER_CLASS' => $select_counter_class, ! 'L_COUNTER_STYLE' => $lang['SiteStats_Counter_Style'], ! 'L_COUNTER_STYLE_EXPLAIN' => $lang['SiteStats_Counter_Styleinfo'], ! 'COUNTER_STYLE' => $new['counter_style'], ! 'L_COUNTER_SIZE' => $lang['SiteStats_Counter_Size'], ! 'L_COUNTER_SIZE_EXPLAIN' => $lang['SiteStats_Counter_Sizeinfo'], ! 'COUNTER_SIZE' => $new['counter_size'], ! 'L_COUNTER_TOSHOW' => $lang['SiteStats_Counter_ToShow'], ! 'L_COUNTER_TOSHOW_EXPLAIN' => $lang['SiteStats_Counter_ToShowinfo'], ! 'COUNTER_TOSHOW' => $new['counters_toshow'], ! 'COUNTER_TOSHOW_HITS' => $counters_toshow_hits, ! 'COUNTER_TOSHOW_SESS' => $counters_toshow_sess, ! 'COUNTER_TOSHOW_BOTH' => $counters_toshow_both, ! 'L_MORE_STATS_PAGE' => $lang['SiteStats_MoreStats_Page'], ! 'L_MORE_STATS_PAGE_EXPLAIN' => $lang['SiteStats_MoreStats_Pageinfo'], ! 'MORE_STATS_PAGE' => $new['more_stats_page'], ! 'L_REFERERS_SETTINGS' => $lang['Referers_Settings'], ! 'L_REFERERS_LOGGING' => $lang['Referers_Logging'], ! 'L_REFERERS_LOGGING_EXPLAIN' => $lang['Referers_Logginginfo'], ! 'REFERERS_LOGGING' => $new['referers_logging'], ! 'REFERERS_LOGGING_ON' => $referers_logging_on, ! 'REFERERS_LOGGING_OFF' => $referers_logging_off, ! 'L_REFERERS_COUNT' => $lang['SiteStats_TopReferers_Count'], ! 'L_REFERERS_COUNT_EXPLAIN' => $lang['SiteStats_TopReferers_Countinfo'], ! 'REFERERS_COUNT' => $new['referers_count'], ! 'L_REFERERS_SHOWDIS' => $lang['SiteStats_TopReferers_ShowDisabled'], ! 'L_REFERERS_SHOWDIS_EXPLAIN' => $lang['SiteStats_TopReferers_ShowDisabledinfo'], ! 'REFERERS_SHOWDIS' => $new['referers_show_disabled'], ! 'REFERERS_SHOWDIS_ON' => $referers_showdis_on, ! 'REFERERS_SHOWDIS_OFF' => $referers_showdis_off, ! 'L_HITS' => $lang['SiteStats_Counter_hits'], ! 'L_SESSIONS' => $lang['SiteStats_Counter_sess'], ! 'L_BOTH' => $lang['Both'], ! 'L_ON' => $lang['On'], ! 'L_OFF' => $lang['Off'], ! 'L_SUBMIT' => $lang['Submit'], ! 'L_RESET' => $lang['Reset'] ) ! ); $template->pparse( 'body' ); include_once( $mx_root_path . 'admin/page_footer_admin.' . $phpEx ); ?> \ No newline at end of file Index: admin_counter.php =================================================================== RCS file: /cvsroot/mxbb/mx_sitestats/admin/admin_counter.php,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** admin_counter.php 2 May 2006 23:29:13 -0000 1.4 --- admin_counter.php 29 Jun 2006 19:08:03 -0000 1.5 *************** *** 13,18 **** // ====================================================== // This is how we add an entry to the phpBB Administration Control Panel... ! if ( !empty( $setmodules ) ) { --- 13,19 ---- // ====================================================== + // // This is how we add an entry to the phpBB Administration Control Panel... ! // if ( !empty( $setmodules ) ) { *************** *** 21,39 **** } // Setup basic portal stuff... ! define( 'IN_PORTAL', 1 ); $mx_root_path = '../../../'; $module_root_path = "../"; // Security and page header... ! $phpEx = substr(strrchr(__FILE__, '.'), 1); $no_page_header = true; require( $mx_root_path . 'admin/pagestart.' . $phpEx ); // Include common module stuff... ! require( $module_root_path . 'includes/common.' . $phpEx ); // ====================================================== // [ GLOBAL DATA ] --- 22,44 ---- } + // // Setup basic portal stuff... ! // define( 'IN_PORTAL', 1 ); $mx_root_path = '../../../'; $module_root_path = "../"; + // // Security and page header... ! // $phpEx = substr(strrchr(__FILE__, '.'), 1); $no_page_header = true; require( $mx_root_path . 'admin/pagestart.' . $phpEx ); + // // Include common module stuff... ! // require( $module_root_path . 'includes/common.' . $phpEx ); + // ====================================================== // [ GLOBAL DATA ] *************** *** 41,57 **** $my_script_name = basename( __FILE__ ); $my_script_title = $lang['SiteStats'] . ': ' . $lang['Counter_Management']; // ====================================================== // [ MAIN PROCESS ] // ====================================================== - // Send page header and set the main template... ! include_once( $mx_root_path . 'admin/page_header_admin.' . $phpEx ); ! $template->set_filenames( array( "body" => "admin/sitestats_counter_admin.tpl" ) ! ); // Check out which mode we operate in... ! if ( isset( $_POST['cancel'] ) ) { --- 46,62 ---- $my_script_name = basename( __FILE__ ); $my_script_title = $lang['SiteStats'] . ': ' . $lang['Counter_Management']; + // ====================================================== // [ MAIN PROCESS ] // ====================================================== // Send page header and set the main template... ! // include_once( $mx_root_path . 'admin/page_header_admin.' . $phpEx ); ! $template->set_filenames( array( "body" => "admin/sitestats_counter_admin.tpl" ) ); + // // Check out which mode we operate in... ! // if ( isset( $_POST['cancel'] ) ) { *************** *** 67,72 **** } // Deal with each mode of operation... ! switch ( $mode ) { --- 72,78 ---- } + // // Deal with each mode of operation... ! // switch ( $mode ) { *************** *** 110,115 **** } // Display counter report... ! $sql = "SELECT * FROM " . SITESTATS_COUNTER_TABLE . " ORDER BY page"; if ( !$result = $db->sql_query( $sql ) ) --- 116,122 ---- } + // // Display counter report... ! // $sql = "SELECT * FROM " . SITESTATS_COUNTER_TABLE . " ORDER BY page"; if ( !$result = $db->sql_query( $sql ) ) *************** *** 123,156 **** $get_vars = '&id=' . $rs_counter[$i]['id'] . '&pg=' . $rs_counter[$i]['page'] . '&ch=' . $rs_counter[$i]['hits_counter'] . '&cs=' . $rs_counter[$i]['sess_counter']; ! $template->assign_block_vars( "counter_rows", array( 'COUNTER_ID' => $rs_counter[$i]['id'], ! 'COUNTER_PAGE' => $rs_counter[$i]['page'], ! 'COUNTER_HITS' => $rs_counter[$i]['hits_counter'], ! 'COUNTER_SESS' => $rs_counter[$i]['sess_counter'], ! 'U_EDIT' => append_sid( $my_script_name . '?mode=edit' . $get_vars ), ! 'U_DELETE' => append_sid( $my_script_name . '?mode=delete' . $get_vars ) ) ! ); } ! $template->assign_vars( array( 'L_PAGE_TITLE' => $my_script_title, ! 'L_PAGE_EXPLAIN' => $lang['Counter_Management_explain'], ! 'L_COUNTER_ID' => $lang['SiteStats_Counter_id'], ! 'L_COUNTER_PAGE' => $lang['SiteStats_Counter_page'], ! 'L_COUNTER_HITS' => $lang['SiteStats_Counter_hits'], ! 'L_COUNTER_SESS' => $lang['SiteStats_Counter_sess'], ! 'L_ADD' => $lang['Add'], ! 'U_ADD' => append_sid( $my_script_name . '?mode=add' ), ! 'L_EDIT' => $lang['Edit'], ! 'L_DELETE' => $lang['Delete'], ! 'L_ACTION' => $lang['Action'] ) ! ); // Send page body/footer and exit... ! $template->pparse( "body" ); include_once( $mx_root_path . 'admin/page_footer_admin.' . $phpEx ); exit; // ====================================================== // [ FUNCTIONS ] --- 130,167 ---- $get_vars = '&id=' . $rs_counter[$i]['id'] . '&pg=' . $rs_counter[$i]['page'] . '&ch=' . $rs_counter[$i]['hits_counter'] . '&cs=' . $rs_counter[$i]['sess_counter']; ! $template->assign_block_vars( "counter_rows", array( ! 'COUNTER_ID' => $rs_counter[$i]['id'], ! 'COUNTER_PAGE' => $rs_counter[$i]['page'], ! 'COUNTER_HITS' => $rs_counter[$i]['hits_counter'], ! 'COUNTER_SESS' => $rs_counter[$i]['sess_counter'], ! 'U_EDIT' => append_sid( $my_script_name . '?mode=edit' . $get_vars ), ! 'U_DELETE' => append_sid( $my_script_name . '?mode=delete' . $get_vars ) ) ! ); } ! $template->assign_vars( array( ! 'L_PAGE_TITLE' => $my_script_title, ! 'L_PAGE_EXPLAIN' => $lang['Counter_Management_explain'], ! 'L_COUNTER_ID' => $lang['SiteStats_Counter_id'], ! 'L_COUNTER_PAGE' => $lang['SiteStats_Counter_page'], ! 'L_COUNTER_HITS' => $lang['SiteStats_Counter_hits'], ! 'L_COUNTER_SESS' => $lang['SiteStats_Counter_sess'], ! 'L_ADD' => $lang['Add'], ! 'U_ADD' => append_sid( $my_script_name . '?mode=add' ), ! 'L_EDIT' => $lang['Edit'], ! 'L_DELETE' => $lang['Delete'], ! 'L_ACTION' => $lang['Action'] ) ! ); + // // Send page body/footer and exit... ! // $template->pparse( "body" ); include_once( $mx_root_path . 'admin/page_footer_admin.' . $phpEx ); exit; + // ====================================================== // [ FUNCTIONS ] *************** *** 159,162 **** --- 170,179 ---- // Dialogs (without templates =:-P) ... + /** + * Enter description here... + * + * @param unknown_type $newmode + * @param unknown_type $errmsg + */ function dialog_addedit( $newmode, $errmsg = '' ) { *************** *** 180,183 **** --- 197,204 ---- } + /** + * Enter description here... + * + */ function dialog_confirm_delete() { *************** *** 194,197 **** --- 215,223 ---- } + /** + * Enter description here... + * + * @param unknown_type $mode + */ function dialog_updated( $mode ) { *************** *** 210,213 **** mx_message_die( GENERAL_MESSAGE, $message, $my_script_title ); } - ?> \ No newline at end of file --- 236,238 ---- |
|
From: Jon O. <jon...@us...> - 2006-06-29 19:07:10
|
Update of /cvsroot/mxbb/mx_quotations/includes In directory sc8-pr-cvs7.sourceforge.net:/tmp/cvs-serv19541/modules/mx_quotations/includes Modified Files: mx_quotations_add.php mx_quotations_del.php mx_quotations_edit.php Log Message: code cleanup Index: mx_quotations_add.php =================================================================== RCS file: /cvsroot/mxbb/mx_quotations/includes/mx_quotations_add.php,v retrieving revision 1.8 retrieving revision 1.9 diff -C2 -d -r1.8 -r1.9 *** mx_quotations_add.php 5 Apr 2006 23:04:08 -0000 1.8 --- mx_quotations_add.php 29 Jun 2006 19:06:57 -0000 1.9 *************** *** 8,12 **** * */ ! if ( !defined( 'IN_PORTAL' ) ) { --- 8,12 ---- * */ ! if ( !defined( 'IN_PORTAL' ) ) { *************** *** 55,66 **** $template->set_filenames( array( "mx_quotations_add" => "mx_quotations_add.tpl" ) ); ! $template->assign_vars( array( 'U_ACTION' => mx_url( 'page', $HTTP_GET_VARS['page'], 'quote_action', 'add' ), ! 'L_QUOTE' => $lang['Quote'], ! 'L_AUTHOR' => $lang['Author'], ! 'L_ADD_QUOTE' => $lang['Add_Quote'], ! 'L_SUBMIT' => $lang['Submit'] ! ) ! ); $template->pparse( "mx_quotations_add" ); } --- 55,67 ---- $template->set_filenames( array( "mx_quotations_add" => "mx_quotations_add.tpl" ) ); ! $template->assign_vars( array( ! 'U_ACTION' => mx_url( 'page', $HTTP_GET_VARS['page'], 'quote_action', 'add' ), ! 'L_QUOTE' => $lang['Quote'], ! 'L_AUTHOR' => $lang['Author'], ! 'L_ADD_QUOTE' => $lang['Add_Quote'], ! 'L_SUBMIT' => $lang['Submit'] ! )); $template->pparse( "mx_quotations_add" ); } + ?> \ No newline at end of file Index: mx_quotations_del.php =================================================================== RCS file: /cvsroot/mxbb/mx_quotations/includes/mx_quotations_del.php,v retrieving revision 1.7 retrieving revision 1.8 diff -C2 -d -r1.7 -r1.8 *** mx_quotations_del.php 5 Apr 2006 23:04:08 -0000 1.7 --- mx_quotations_del.php 29 Jun 2006 19:06:57 -0000 1.8 *************** *** 63,76 **** $template->set_filenames( array( "mx_quotations_del" => "mx_quotations_del.tpl" ) ); ! $template->assign_vars( array( 'U_ACTION' => mx_url( 'page', $HTTP_GET_VARS['page'], 'quote_action', 'del', 'quote_id', $HTTP_GET_VARS['quote_id'] ), ! 'L_QUOTE' => $lang['Quote'], ! 'L_AUTHOR' => $lang['Author'], ! 'L_DELETE_QUOTE' => $lang['Delete_Quote'], ! 'L_DELETE' => $lang['Delete'], ! 'L_CANCEL' => $lang['Cancel'], ! 'QUOTE' => $quote, ! 'AUTHOR' => $author ! ) ! ); $template->pparse( "mx_quotations_del" ); --- 63,76 ---- $template->set_filenames( array( "mx_quotations_del" => "mx_quotations_del.tpl" ) ); ! $template->assign_vars( array( ! 'U_ACTION' => mx_url( 'page', $HTTP_GET_VARS['page'], 'quote_action', 'del', 'quote_id', $HTTP_GET_VARS['quote_id'] ), ! 'L_QUOTE' => $lang['Quote'], ! 'L_AUTHOR' => $lang['Author'], ! 'L_DELETE_QUOTE' => $lang['Delete_Quote'], ! 'L_DELETE' => $lang['Delete'], ! 'L_CANCEL' => $lang['Cancel'], ! 'QUOTE' => $quote, ! 'AUTHOR' => $author ! )); $template->pparse( "mx_quotations_del" ); *************** *** 78,79 **** --- 78,80 ---- $db->sql_freeresult( $result1 ); } + ?> \ No newline at end of file Index: mx_quotations_edit.php =================================================================== RCS file: /cvsroot/mxbb/mx_quotations/includes/mx_quotations_edit.php,v retrieving revision 1.8 retrieving revision 1.9 diff -C2 -d -r1.8 -r1.9 *** mx_quotations_edit.php 5 Apr 2006 23:04:08 -0000 1.8 --- mx_quotations_edit.php 29 Jun 2006 19:06:57 -0000 1.9 *************** *** 8,12 **** * */ ! if ( !defined( 'IN_PORTAL' ) ) { --- 8,12 ---- * */ ! if ( !defined( 'IN_PORTAL' ) ) { *************** *** 78,90 **** $template->set_filenames( array( "mx_quotations_edit" => "mx_quotations_edit.tpl" ) ); ! $template->assign_vars( array( 'U_ACTION' => mx_url( 'page', $HTTP_GET_VARS['page'], 'quote_action', 'edit', 'quote_id', $HTTP_GET_VARS['quote_id'] ), ! 'L_QUOTE' => $lang['Quote'], ! 'L_AUTHOR' => $lang['Author'], ! 'L_EDIT_QUOTE' => $lang['Edit_Quote'], ! 'L_SUBMIT' => $lang['Submit'], ! 'QUOTE' => $quote, ! 'AUTHOR' => $author ! ) ! ); $template->pparse( "mx_quotations_edit" ); --- 78,90 ---- $template->set_filenames( array( "mx_quotations_edit" => "mx_quotations_edit.tpl" ) ); ! $template->assign_vars( array( ! 'U_ACTION' => mx_url( 'page', $HTTP_GET_VARS['page'], 'quote_action', 'edit', 'quote_id', $HTTP_GET_VARS['quote_id'] ), ! 'L_QUOTE' => $lang['Quote'], ! 'L_AUTHOR' => $lang['Author'], ! 'L_EDIT_QUOTE' => $lang['Edit_Quote'], ! 'L_SUBMIT' => $lang['Submit'], ! 'QUOTE' => $quote, ! 'AUTHOR' => $author ! )); $template->pparse( "mx_quotations_edit" ); *************** *** 92,93 **** --- 92,94 ---- $db->sql_freeresult( $result1 ); } + ?> \ No newline at end of file |
|
From: Jon O. <jon...@us...> - 2006-06-29 19:07:09
|
Update of /cvsroot/mxbb/mx_quotations In directory sc8-pr-cvs7.sourceforge.net:/tmp/cvs-serv19541/modules/mx_quotations Modified Files: mx_last_quotations.php mx_quotations.php mx_random_quotation.php Log Message: code cleanup Index: mx_last_quotations.php =================================================================== RCS file: /cvsroot/mxbb/mx_quotations/mx_last_quotations.php,v retrieving revision 1.9 retrieving revision 1.10 diff -C2 -d -r1.9 -r1.10 *** mx_last_quotations.php 17 Jun 2006 20:50:15 -0000 1.9 --- mx_last_quotations.php 29 Jun 2006 19:06:57 -0000 1.10 *************** *** 33,38 **** $title = $mx_block->block_info['block_title']; // Get all data ! if ( !file_exists( $module_root_path . 'language/lang_' . $board_config['default_lang'] . '/lang_main.' . $phpEx ) ) { --- 33,39 ---- $title = $mx_block->block_info['block_title']; + // // Get all data ! // if ( !file_exists( $module_root_path . 'language/lang_' . $board_config['default_lang'] . '/lang_main.' . $phpEx ) ) { *************** *** 59,64 **** $author = array(); ! $template->set_filenames( array( "mx_last_quotations" => "mx_last_quotations.tpl" ) ! ); $row = $db->sql_fetchrowset( $result ); --- 60,64 ---- $author = array(); ! $template->set_filenames( array( "mx_last_quotations" => "mx_last_quotations.tpl" ) ); $row = $db->sql_fetchrowset( $result ); *************** *** 77,88 **** $poster .= ( $row[$row_count]['poster_id'] != -1 ) ? '</a>' : ''; ! $template->assign_block_vars( "quote_row", array( 'ROW_COLOR' => "#" . $row_color, ! 'ROW_CLASS' => $row_class, ! 'QUOTE' => $quote, ! 'AUTHOR' => $author, ! 'POSTER' => $poster, ! 'POST_TIME' => $post_time ! ) ! ); } } --- 77,88 ---- $poster .= ( $row[$row_count]['poster_id'] != -1 ) ? '</a>' : ''; ! $template->assign_block_vars( "quote_row", array( ! 'ROW_COLOR' => "#" . $row_color, ! 'ROW_CLASS' => $row_class, ! 'QUOTE' => $quote, ! 'AUTHOR' => $author, ! 'POSTER' => $poster, ! 'POST_TIME' => $post_time ! )); } } *************** *** 98,111 **** // Start output of page ! $template->assign_vars( array( 'L_AUTHOR' => ( !empty( $lang['Author'] ) ? $lang['Author'] : 'Author' ), ! 'L_QUOTE' => ( !empty( $lang['Quote'] ) ? $lang['Quote'] : 'Quote' ), ! 'BLOCK_SIZE' => ( !empty( $block_size ) ? $block_size : '100%' ), ! 'L_TITLE' => ( !empty( $lang[$title] ) ? $lang[$title] : $title ), ! 'L_POSTED_BY' => ( !empty( $lang['Posted_by'] ) ? $lang['Posted_by'] : 'Posted by:' ) ) ! ); $template->pparse( "mx_last_quotations" ); $db->sql_freeresult( $result ); - ?> \ No newline at end of file --- 98,111 ---- // Start output of page ! $template->assign_vars( array( ! 'L_AUTHOR' => ( !empty( $lang['Author'] ) ? $lang['Author'] : 'Author' ), ! 'L_QUOTE' => ( !empty( $lang['Quote'] ) ? $lang['Quote'] : 'Quote' ), ! 'BLOCK_SIZE' => ( !empty( $block_size ) ? $block_size : '100%' ), ! 'L_TITLE' => ( !empty( $lang[$title] ) ? $lang[$title] : $title ), ! 'L_POSTED_BY' => ( !empty( $lang['Posted_by'] ) ? $lang['Posted_by'] : 'Posted by:' ) ) ! ); $template->pparse( "mx_last_quotations" ); $db->sql_freeresult( $result ); ?> \ No newline at end of file Index: mx_random_quotation.php =================================================================== RCS file: /cvsroot/mxbb/mx_quotations/mx_random_quotation.php,v retrieving revision 1.7 retrieving revision 1.8 diff -C2 -d -r1.7 -r1.8 *** mx_random_quotation.php 5 Apr 2006 23:04:07 -0000 1.7 --- mx_random_quotation.php 29 Jun 2006 19:06:57 -0000 1.8 *************** *** 9,13 **** */ ! // // Set up for phpBB intergration. // --- 9,13 ---- */ ! // // Set up for phpBB intergration. // *************** *** 24,29 **** $title = $mx_block->block_info['block_title']; // Get all data ! if ( !file_exists( $module_root_path . 'language/lang_' . $board_config['default_lang'] . '/lang_main.' . $phpEx ) ) { --- 24,30 ---- $title = $mx_block->block_info['block_title']; + // // Get all data ! // if ( !file_exists( $module_root_path . 'language/lang_' . $board_config['default_lang'] . '/lang_main.' . $phpEx ) ) { *************** *** 49,54 **** $author = array(); ! $template->set_filenames( array( "mx_random_quotation" => "mx_random_quotation.tpl" ) ! ); $row = $db->sql_fetchrowset( $result ); --- 50,54 ---- $author = array(); ! $template->set_filenames( array( "mx_random_quotation" => "mx_random_quotation.tpl" ) ); $row = $db->sql_fetchrowset( $result ); *************** *** 62,71 **** $poster .= ( $row[0]['poster_id'] != -1 ) ? '</a>' : ''; ! $template->assign_vars( array( 'QUOTE' => $quote, ! 'AUTHOR' => $author, ! 'POSTER' => $poster, ! 'POST_TIME' => $post_time ! ) ! ); $template->assign_block_vars( 'switch_quotes_found', array() ); } --- 62,72 ---- $poster .= ( $row[0]['poster_id'] != -1 ) ? '</a>' : ''; ! $template->assign_vars( array( ! 'QUOTE' => $quote, ! 'AUTHOR' => $author, ! 'POSTER' => $poster, ! 'POST_TIME' => $post_time ! )); ! $template->assign_block_vars( 'switch_quotes_found', array() ); } *************** *** 73,79 **** { $no_quotes_msg = ( !empty( $lang['No_quotes'] ) ? $lang['No_quotes'] : 'Sorry No Quotes' ); ! $template->assign_vars( array( 'L_NO_QUOTES' => $no_quotes_msg ) ! ); ! $template->assign_block_vars( 'switch_no_quotes', array() ); } --- 74,78 ---- { $no_quotes_msg = ( !empty( $lang['No_quotes'] ) ? $lang['No_quotes'] : 'Sorry No Quotes' ); ! $template->assign_vars( array( 'L_NO_QUOTES' => $no_quotes_msg ) ); $template->assign_block_vars( 'switch_no_quotes', array() ); } *************** *** 81,93 **** // Start output of page ! $template->assign_vars( array( 'BLOCK_SIZE' => ( !empty( $block_size ) ? $block_size : '100%' ), ! 'L_TITLE' => ( !empty( $lang[$title] ) ? $lang[$title] : $title ), ! 'L_POSTED_BY' => ( !empty( $lang['Posted_by'] ) ? $lang['Posted_by'] : 'Posted by:' ), ! 'U_QUOTES' => append_sid( $mx_root_path . 'index.php?page=8' ) ! ) ); $template->pparse( "mx_random_quotation" ); - $db->sql_freeresult( $result ); - ?> \ No newline at end of file --- 80,91 ---- // Start output of page ! $template->assign_vars( array( ! 'BLOCK_SIZE' => ( !empty( $block_size ) ? $block_size : '100%' ), ! 'L_TITLE' => ( !empty( $lang[$title] ) ? $lang[$title] : $title ), ! 'L_POSTED_BY' => ( !empty( $lang['Posted_by'] ) ? $lang['Posted_by'] : 'Posted by:' ), ! 'U_QUOTES' => append_sid( $mx_root_path . 'index.php?page=8' ) ! ) ); $template->pparse( "mx_random_quotation" ); $db->sql_freeresult( $result ); ?> \ No newline at end of file Index: mx_quotations.php =================================================================== RCS file: /cvsroot/mxbb/mx_quotations/mx_quotations.php,v retrieving revision 1.13 retrieving revision 1.14 diff -C2 -d -r1.13 -r1.14 *** mx_quotations.php 17 Jun 2006 20:50:15 -0000 1.13 --- mx_quotations.php 29 Jun 2006 19:06:57 -0000 1.14 *************** *** 112,119 **** } // Get all data ! $letters = $lang['lang_letters_array']; // Is this a search?? if ( isset( $HTTP_POST_VARS['search_string'] ) ) { --- 112,123 ---- } + // // Get all data ! // $letters = $lang['lang_letters_array']; + + // // Is this a search?? + // if ( isset( $HTTP_POST_VARS['search_string'] ) ) { *************** *** 166,170 **** WHERE " . $not_like . " ORDER BY q.author"; ! }elseif ( $initial == 'all' ) { $all = 1; --- 170,175 ---- WHERE " . $not_like . " ORDER BY q.author"; ! } ! elseif ( $initial == 'all' ) { $all = 1; *************** *** 176,180 **** } else // if $initial is set and it is not all and is not other -> it is a letter ! { $initial = ( $initial != "" ) ? "'" . $initial{0} . "%'" : "NULL"; --- 181,185 ---- } else // if $initial is set and it is not all and is not other -> it is a letter ! { $initial = ( $initial != "" ) ? "'" . $initial{0} . "%'" : "NULL"; *************** *** 246,249 **** --- 251,255 ---- } } + if ( !( $result = $db->sql_query( $sql ) ) ) { *************** *** 285,300 **** } ! $template->assign_block_vars( "quote_row", array( 'ROW_COLOR' => "#" . $row_color, ! 'ROW_CLASS' => $row_class, ! 'QUOTE' => $quote, ! 'AUTHOR' => $author, ! 'POSTER' => $poster, ! 'POST_TIME' => $post_time, ! 'U_DELETE_QUOTE' => $u_delete_quote, ! 'U_EDIT_QUOTE' => $u_edit_quote, ! 'L_DELETE_QUOTE' => $l_delete_quote, ! 'L_EDIT_QUOTE' => $l_edit_quote ! ) ! ); } } --- 291,306 ---- } ! $template->assign_block_vars( "quote_row", array( ! 'ROW_COLOR' => "#" . $row_color, ! 'ROW_CLASS' => $row_class, ! 'QUOTE' => $quote, ! 'AUTHOR' => $author, ! 'POSTER' => $poster, ! 'POST_TIME' => $post_time, ! 'U_DELETE_QUOTE' => $u_delete_quote, ! 'U_EDIT_QUOTE' => $u_edit_quote, ! 'L_DELETE_QUOTE' => $l_delete_quote, ! 'L_EDIT_QUOTE' => $l_edit_quote ! )); } } *************** *** 302,308 **** { $no_quotes_msg = ( !empty( $lang['No_quotes'] ) ? $lang['No_quotes'] : 'Sorry No Quotes' ); ! $template->assign_vars( array( 'L_NO_QUOTES' => $no_quotes_msg ) ! ); ! $template->assign_block_vars( 'switch_no_quotes', array() ); } --- 308,312 ---- { $no_quotes_msg = ( !empty( $lang['No_quotes'] ) ? $lang['No_quotes'] : 'Sorry No Quotes' ); ! $template->assign_vars( array( 'L_NO_QUOTES' => $no_quotes_msg ) ); $template->assign_block_vars( 'switch_no_quotes', array() ); } *************** *** 346,368 **** } ! $template->assign_vars( array( 'L_TITLE' => ( !empty( $lang['Quotations'] ) ? $lang['Quotations'] : 'Quotations' ), ! 'L_AUTHOR' => ( !empty( $lang['Author'] ) ? $lang['Author'] : 'Author' ), ! 'L_QUOTE' => ( !empty( $lang['Quote'] ) ? $lang['Quote'] : 'Quote' ), ! 'L_ADD_QUOTE' => $l_add_quote, ! 'L_SELECT_INITIAL' => ( !empty( $lang['Select_initial'] ) ? $lang['Select_initial'] : 'Browse titles in the quotations section by letter:' ), ! 'L_SEARCH' => ( !empty( $lang['Search'] ) ? $lang['Search'] : 'Search' ), ! 'L_KEYWORD_SEARCH' => ( !empty( $lang['Keyword_search'] ) ? $lang['Keyword_search'] : 'Keyword_search' ), ! 'L_POSTED_BY' => ( !empty( $lang['Posted_by'] ) ? $lang['Posted_by'] : 'Posted by:' ), ! 'U_PHPBB_ROOT_PATH' => PHPBB_URL, ! 'U_PORTAL_ROOT_PATH' => PORTAL_URL, ! 'U_ADD_QUOTE' => $u_add_quote, ! 'U_FORM_ACTION' => append_sid( $mx_root_path . ( $is_block ? "index.$phpEx?page=$page_id" : "modules/mx_quotations/mx_quotations.$phpEx" ) ), ! 'BLOCK_SIZE' => $block_size, ! 'TEMPLATE_ROOT_PATH' => TEMPLATE_ROOT_PATH, ! 'INITIALS' => $initial_links ! ) ! ); $template->pparse( "mx_quotations" ); --- 350,372 ---- } ! $template->assign_vars( array( ! 'L_TITLE' => ( !empty( $lang['Quotations'] ) ? $lang['Quotations'] : 'Quotations' ), ! 'L_AUTHOR' => ( !empty( $lang['Author'] ) ? $lang['Author'] : 'Author' ), ! 'L_QUOTE' => ( !empty( $lang['Quote'] ) ? $lang['Quote'] : 'Quote' ), ! 'L_ADD_QUOTE' => $l_add_quote, ! 'L_SELECT_INITIAL' => ( !empty( $lang['Select_initial'] ) ? $lang['Select_initial'] : 'Browse titles in the quotations section by letter:' ), ! 'L_SEARCH' => ( !empty( $lang['Search'] ) ? $lang['Search'] : 'Search' ), ! 'L_KEYWORD_SEARCH' => ( !empty( $lang['Keyword_search'] ) ? $lang['Keyword_search'] : 'Keyword_search' ), ! 'L_POSTED_BY' => ( !empty( $lang['Posted_by'] ) ? $lang['Posted_by'] : 'Posted by:' ), ! 'U_PHPBB_ROOT_PATH' => PHPBB_URL, ! 'U_PORTAL_ROOT_PATH' => PORTAL_URL, ! 'U_ADD_QUOTE' => $u_add_quote, ! 'U_FORM_ACTION' => append_sid( $mx_root_path . ( $is_block ? "index.$phpEx?page=$page_id" : "modules/mx_quotations/mx_quotations.$phpEx" ) ), ! 'BLOCK_SIZE' => $block_size, ! 'TEMPLATE_ROOT_PATH' => TEMPLATE_ROOT_PATH, ! 'INITIALS' => $initial_links ! )); $template->pparse( "mx_quotations" ); *************** *** 373,376 **** $mx_page->add_copyright( 'mxBB quotations Module' ); } - ?> \ No newline at end of file --- 377,379 ---- |
|
From: Jon O. <jon...@us...> - 2006-06-29 19:07:00
|
Update of /cvsroot/mxbb/mx_quotations/language/lang_english In directory sc8-pr-cvs7.sourceforge.net:/tmp/cvs-serv19541/modules/mx_quotations/language/lang_english Modified Files: lang_main.php Log Message: code cleanup Index: lang_main.php =================================================================== RCS file: /cvsroot/mxbb/mx_quotations/language/lang_english/lang_main.php,v retrieving revision 1.6 retrieving revision 1.7 diff -C2 -d -r1.6 -r1.7 *** lang_main.php 5 Apr 2006 23:04:08 -0000 1.6 --- lang_main.php 29 Jun 2006 19:06:57 -0000 1.7 *************** *** 8,12 **** * */ ! // // The format of this file is: --- 8,12 ---- * */ ! // // The format of this file is: *************** *** 45,48 **** // That's all Folks! // ------------------------------------------------- - ?> \ No newline at end of file --- 45,47 ---- |
|
From: Jon O. <jon...@us...> - 2006-06-29 19:05:51
|
Update of /cvsroot/mxbb/mx_calsnails In directory sc8-pr-cvs7.sourceforge.net:/tmp/cvs-serv19076/modules/mx_calsnails Modified Files: calendar.php Log Message: update Index: calendar.php =================================================================== RCS file: /cvsroot/mxbb/mx_calsnails/calendar.php,v retrieving revision 1.26 retrieving revision 1.27 diff -C2 -d -r1.26 -r1.27 *** calendar.php 29 Jun 2006 13:39:03 -0000 1.26 --- calendar.php 29 Jun 2006 19:05:39 -0000 1.27 *************** *** 76,84 **** $page_id = ( !empty( $HTTP_POST_VARS['page'] ) ) ? $HTTP_POST_VARS['page'] : $HTTP_GET_VARS['page']; - /*########################################## - ## STOP # - ## DO NOT MODIFY ANYTHING BELOW THIS LINE # - ##########################################*/ - // // Security Check --- 76,79 ---- *************** *** 106,110 **** 'event_desc' => 'message', // MX011 'modify' => 'modify', ! ); while ( list( $var, $param ) = @each( $params ) ) --- 101,105 ---- 'event_desc' => 'message', // MX011 'modify' => 'modify', ! ); while ( list( $var, $param ) = @each( $params ) ) |
|
From: Jon O. <jon...@us...> - 2006-06-29 19:05:14
|
Update of /cvsroot/mxbb/core/templates/subSilver In directory sc8-pr-cvs7.sourceforge.net:/tmp/cvs-serv18902/templates/subSilver Modified Files: overall_header2.tpl overall_header_navigation.tpl Log Message: minor tpl fix Index: overall_header2.tpl =================================================================== RCS file: /cvsroot/mxbb/core/templates/subSilver/overall_header2.tpl,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** overall_header2.tpl 5 Apr 2006 20:53:00 -0000 1.1 --- overall_header2.tpl 29 Jun 2006 19:05:04 -0000 1.2 *************** *** 51,55 **** window.open('{U_SEARCH_PAFILEDB}&search_keywords=' + document.search_block.search_keywords.value, '_self', ''); return false; ! } else { --- 51,55 ---- window.open('{U_SEARCH_PAFILEDB}&search_keywords=' + document.search_block.search_keywords.value, '_self', ''); return false; ! } else { *************** *** 67,71 **** <a name="top"></a> ! <table width="100%" cellspacing="0" cellpadding="0" border="0" align="center" class="mx_main_table"> <tr> <td class="bodyline"> --- 67,71 ---- <a name="top"></a> ! <table width="100%" cellspacing="0" cellpadding="1" border="0" align="center" class="mx_main_table"> <tr> <td class="bodyline"> *************** *** 115,127 **** </tr> <!-- BEGIN switch_view --> ! <tr> <td align="left" valign="bottom" colspan="3" ><span class="gensmall">{CURRENT_TIME}</span></td> </tr> ! <tr> <td align="left" valign="bottom" colspan="3" ><span class="nav"><a href="{U_INDEX}" class="nav">{L_INDEX}</a></span></td> </tr> <!-- END switch_view --> </table> ! <table width="100%" cellspacing="0" cellpadding="2" border="0" align="center"> <tr> --- 115,127 ---- </tr> <!-- BEGIN switch_view --> ! <tr> <td align="left" valign="bottom" colspan="3" ><span class="gensmall">{CURRENT_TIME}</span></td> </tr> ! <tr> <td align="left" valign="bottom" colspan="3" ><span class="nav"><a href="{U_INDEX}" class="nav">{L_INDEX}</a></span></td> </tr> <!-- END switch_view --> </table> ! <table width="100%" cellspacing="0" cellpadding="2" border="0" align="center"> <tr> *************** *** 147,151 **** </tr> </table> ! <!-- BEGIN phpbb_stats --> <table width="100%" cellspacing="0" cellpadding="2" border="0" align="center"> --- 147,151 ---- </tr> </table> ! <!-- BEGIN phpbb_stats --> <table width="100%" cellspacing="0" cellpadding="2" border="0" align="center"> *************** *** 165,167 **** </tr> </table> ! <!-- END phpbb_stats --> \ No newline at end of file --- 165,167 ---- </tr> </table> ! <!-- END phpbb_stats --> \ No newline at end of file Index: overall_header_navigation.tpl =================================================================== RCS file: /cvsroot/mxbb/core/templates/subSilver/overall_header_navigation.tpl,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** overall_header_navigation.tpl 5 Apr 2006 20:53:01 -0000 1.1 --- overall_header_navigation.tpl 29 Jun 2006 19:05:04 -0000 1.2 *************** *** 51,55 **** window.open('{U_SEARCH_PAFILEDB}&search_keywords=' + document.search_block.search_keywords.value, '_self', ''); return false; ! } else { --- 51,55 ---- window.open('{U_SEARCH_PAFILEDB}&search_keywords=' + document.search_block.search_keywords.value, '_self', ''); return false; ! } else { *************** *** 67,71 **** <a name="top"></a> ! <table width="100%" cellspacing="0" cellpadding="0" border="0" align="center" class="mx_main_table"> <tr> <td class="bodyline"> --- 67,71 ---- <a name="top"></a> ! <table width="100%" cellspacing="0" cellpadding="1" border="0" align="center" class="mx_main_table"> <tr> <td class="bodyline"> *************** *** 84,91 **** <!-- BEGIN switch_view --> ! <tr> <td align="left" valign="bottom" colspan="3" ><span class="gensmall">{CURRENT_TIME}</span></td> </tr> ! <tr> <td align="left" valign="bottom" colspan="3" ><span class="nav"><a href="{U_INDEX}" class="nav">{L_INDEX}</a></span></td> </tr> --- 84,91 ---- <!-- BEGIN switch_view --> ! <tr> <td align="left" valign="bottom" colspan="3" ><span class="gensmall">{CURRENT_TIME}</span></td> </tr> ! <tr> <td align="left" valign="bottom" colspan="3" ><span class="nav"><a href="{U_INDEX}" class="nav">{L_INDEX}</a></span></td> </tr> *************** *** 93,107 **** </table> ! <table width="100%" cellspacing="0" cellpadding="2" border="0" align="center"> <tr> <td align="center" valign="middle" nowrap> <a href="{U_LOGIN_LOGOUT}" class="mainmenu"><img src="{NAV_IMAGES_LOGIN_LOGOUT}" class="mx_icon" border="0" alt="" hspace="1" align="middle" /></a><span class="mainmenu"><a href="{U_LOGIN_LOGOUT}" class="mainmenu">{L_LOGIN_LOGOUT}</a></span> ! </td> <td align="center" valign="middle" nowrap> <!-- BEGIN switch_user_logged_out --> <a href="{U_REGISTER}" class="mainmenu"><img src="{NAV_IMAGES_REGISTER}" class="mx_icon" border="0" alt="" hspace="1" align="middle" /></a><span class="mainmenu"><a href="{U_REGISTER}" class="mainmenu">{L_REGISTER}</a></span> <!-- END switch_user_logged_out --> ! </td> <td valign="top" align="right" width="100%" height="5" > <form name="search_block" method="post" action="{U_SEARCH}" onsubmit="return checkSearch()"> --- 93,107 ---- </table> ! <table width="100%" cellspacing="0" cellpadding="2" border="0" align="center"> <tr> <td align="center" valign="middle" nowrap> <a href="{U_LOGIN_LOGOUT}" class="mainmenu"><img src="{NAV_IMAGES_LOGIN_LOGOUT}" class="mx_icon" border="0" alt="" hspace="1" align="middle" /></a><span class="mainmenu"><a href="{U_LOGIN_LOGOUT}" class="mainmenu">{L_LOGIN_LOGOUT}</a></span> ! </td> <td align="center" valign="middle" nowrap> <!-- BEGIN switch_user_logged_out --> <a href="{U_REGISTER}" class="mainmenu"><img src="{NAV_IMAGES_REGISTER}" class="mx_icon" border="0" alt="" hspace="1" align="middle" /></a><span class="mainmenu"><a href="{U_REGISTER}" class="mainmenu">{L_REGISTER}</a></span> <!-- END switch_user_logged_out --> ! </td> <td valign="top" align="right" width="100%" height="5" > <form name="search_block" method="post" action="{U_SEARCH}" onsubmit="return checkSearch()"> *************** *** 125,129 **** </tr> </table> ! <!-- BEGIN phpbb_stats --> <table width="100%" cellspacing="0" cellpadding="2" border="0" align="center"> --- 125,129 ---- </tr> </table> ! <!-- BEGIN phpbb_stats --> <table width="100%" cellspacing="0" cellpadding="2" border="0" align="center"> *************** *** 143,146 **** </tr> </table> ! <!-- END phpbb_stats --> ! \ No newline at end of file --- 143,145 ---- </tr> </table> ! <!-- END phpbb_stats --> |
|
From: Jon O. <jon...@us...> - 2006-06-29 13:39:09
|
Update of /cvsroot/mxbb/mx_calsnails/language/lang_english In directory sc8-pr-cvs7.sourceforge.net:/tmp/cvs-serv4127/modules/mx_calsnails/language/lang_english Modified Files: lang_admin.php lang_main.php Log Message: Code cleanup Index: lang_main.php =================================================================== RCS file: /cvsroot/mxbb/mx_calsnails/language/lang_english/lang_main.php,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** lang_main.php 5 Apr 2006 22:10:14 -0000 1.4 --- lang_main.php 29 Jun 2006 13:39:03 -0000 1.5 *************** *** 44,49 **** $lang['No time'] = "You must select a start and end time"; ! // New Version 2.0.0 Additions. $lang['Config_Calendar'] = "Calendar Configuration"; $lang['Config_Calendar_explain'] = "Set all the necessary variables for your calendar below"; --- 44,50 ---- $lang['No time'] = "You must select a start and end time"; ! // // New Version 2.0.0 Additions. + // $lang['Config_Calendar'] = "Calendar Configuration"; $lang['Config_Calendar_explain'] = "Set all the necessary variables for your calendar below"; *************** *** 54,58 **** $lang['subject_length'] = "Subject length"; $lang['subject_length_explain'] = "Set the length of characters in an event subject(title) for the main month view<br><i>NB: For double-byte languages always select an even number of characters</i>"; ! $lang['cal_script_path_explain'] = "NOT CURRENTLY IN USE"; $lang['allow_anon'] = "Allow anonymous viewing"; $lang['allow_old'] = "Allow old events"; --- 55,59 ---- $lang['subject_length'] = "Subject length"; $lang['subject_length_explain'] = "Set the length of characters in an event subject(title) for the main month view<br><i>NB: For double-byte languages always select an even number of characters</i>"; ! $lang['cal_script_path_explain'] = "NOT CURRENTLY IN USE"; $lang['allow_anon'] = "Allow anonymous viewing"; $lang['allow_old'] = "Allow old events"; *************** *** 64,68 **** $lang['Cal_config_updated'] = "Calendar Configuration Updated Sucessfully"; ! $lang['Cal_return_config'] = 'Click %sHere%s to return to Calendar Configuration'; $lang['allow_categories'] = "Use categories with events"; $lang['require_categories'] = "Require a category with events:"; --- 65,69 ---- $lang['Cal_config_updated'] = "Calendar Configuration Updated Sucessfully"; ! $lang['Cal_return_config'] = 'Click %sHere%s to return to Calendar Configuration'; $lang['allow_categories'] = "Use categories with events"; $lang['require_categories'] = "Require a category with events:"; *************** *** 159,164 **** $lang['Cat_in_use'] = "This category is linked to existing events and cannot be deleted"; // DEV lang 2.0.25 ! $lang['require_time'] = "Require start/end times to be entered with new events"; $lang['allow_private_event'] = "Allow registered users to add private events"; --- 160,166 ---- $lang['Cat_in_use'] = "This category is linked to existing events and cannot be deleted"; + // // DEV lang 2.0.25 ! // $lang['require_time'] = "Require start/end times to be entered with new events"; $lang['allow_private_event'] = "Allow registered users to add private events"; *************** *** 175,180 **** $lang['time_format'] = "Time Format"; // DEV lang 2.0.31 ! $lang['c_first'] = '1st'; $lang['c_second'] = '2nd'; --- 177,183 ---- $lang['time_format'] = "Time Format"; + // // DEV lang 2.0.31 ! // $lang['c_first'] = '1st'; $lang['c_second'] = '2nd'; *************** *** 206,209 **** $lang['Ev_this_month'] = 'This month '; $lang['Ev_next_month'] = 'Next month '; - ?> \ No newline at end of file --- 209,211 ---- Index: lang_admin.php =================================================================== RCS file: /cvsroot/mxbb/mx_calsnails/language/lang_english/lang_admin.php,v retrieving revision 1.10 retrieving revision 1.11 diff -C2 -d -r1.10 -r1.11 *** lang_admin.php 5 Apr 2006 22:10:13 -0000 1.10 --- lang_admin.php 29 Jun 2006 13:39:03 -0000 1.11 *************** *** 26,30 **** // Block Parameter Specific // ----------------------------------- - $lang['Calendar_Block_Title'] = "Block title"; $lang['Calendar_Block_Title_explain'] = "This parameter allows you to override the default block title (you may use something meaningfull depending on the Range used)."; --- 26,29 ---- *************** *** 54,61 **** $lang['cal_mod_group'] = "CalSnails Moderator Group"; - // // That's all Folks! // ------------------------------------------------- - ?> \ No newline at end of file --- 53,58 ---- |
Update of /cvsroot/mxbb/mx_calsnails In directory sc8-pr-cvs7.sourceforge.net:/tmp/cvs-serv4127/modules/mx_calsnails Modified Files: calendar.php db_install.php db_uninstall.php db_upgrade.php mx_calendar_events.php mx_calendar_query.php Log Message: Code cleanup Index: mx_calendar_query.php =================================================================== RCS file: /cvsroot/mxbb/mx_calsnails/mx_calendar_query.php,v retrieving revision 1.13 retrieving revision 1.14 diff -C2 -d -r1.13 -r1.14 *** mx_calendar_query.php 17 Jun 2006 20:45:55 -0000 1.13 --- mx_calendar_query.php 29 Jun 2006 13:39:03 -0000 1.14 *************** *** 35,40 **** } // Security Check ! if ( isset( $HTTP_GET_VARS['caluser'] ) || isset( $HTTP_POST_VARS['caluser'] ) || isset( $caluser ) ) { --- 35,41 ---- } + // // Security Check ! // if ( isset( $HTTP_GET_VARS['caluser'] ) || isset( $HTTP_POST_VARS['caluser'] ) || isset( $caluser ) ) { *************** *** 49,52 **** --- 50,54 ---- $caluser = ( $userdata['user_id'] == ANONYMOUS ? $cal_config['allow_anon'] : $cal_config['allow_user_default'] ); } + // -------------------------------------------------------------------------------- // Check if the user can see. Otherwise, nothing to do. *************** *** 55,60 **** { // -------------------------------------------------------------------------------- ! $template->set_filenames( array( 'body' => 'mx_calendar_query.tpl' ) ! ); $sql = "SELECT * FROM " . CALLITE_EVENTS_TABLE . " WHERE valid = 'yes'"; --- 57,61 ---- { // -------------------------------------------------------------------------------- ! $template->set_filenames( array( 'body' => 'mx_calendar_query.tpl' ) ); $sql = "SELECT * FROM " . CALLITE_EVENTS_TABLE . " WHERE valid = 'yes'"; *************** *** 71,74 **** --- 72,76 ---- mx_message_die( GENERAL_ERROR, 'Could not select Event data', '', __LINE__, __FILE__, $sql ); } + $check = 0; while ( $row = $db->sql_fetchrow( $result ) ) *************** *** 76,98 **** if ( $check == 0 ) { ! $template->assign_block_vars( 'event_row', array( 'ROW_CLASS' => 'catHead', ! 'EVENT_ID' => '<b>ID</b>', ! 'SUBJECT' => '<b>SUBJECT</b>', ! 'DATE' => '<b>STAMP</b>', ! 'END_DATE' => '<b>EVENTSPAN</b>', ! 'DESC' => '<b>DESCRIPTION</b>', ! 'BBTEXT' => '', ! 'AUTHOR' => '<b>USERNAME</b>' ) ! ); ! } ! $template->assign_block_vars( 'event_row', array( 'ROW_CLASS' => ( $check % 2 == 0 ) ? 'row1' : 'row2', ! 'EVENT_ID' => stripslashes( $row['event_id'] ), ! 'SUBJECT' => stripslashes( $row['subject'] ), ! 'DATE' => my_dateformat( $row['stamp'], $block_datefmt ), ! 'END_DATE' => my_dateformat( $row['eventspan'], $block_datefmt, 1 ), ! 'DESC' => stripslashes( $row['description'] ), ! 'BBTEXT' => my_decode_bbtext( $row['description'], $row['bbcode_uid'] ), ! 'AUTHOR' => stripslashes( $row['username'] ) ) ); $check++; } --- 78,103 ---- if ( $check == 0 ) { ! $template->assign_block_vars( 'event_row', array( ! 'ROW_CLASS' => 'catHead', ! 'EVENT_ID' => '<b>ID</b>', ! 'SUBJECT' => '<b>SUBJECT</b>', ! 'DATE' => '<b>STAMP</b>', ! 'END_DATE' => '<b>EVENTSPAN</b>', ! 'DESC' => '<b>DESCRIPTION</b>', ! 'BBTEXT' => '', ! 'AUTHOR' => '<b>USERNAME</b>' ) ); + } + + $template->assign_block_vars( 'event_row', array( + 'ROW_CLASS' => ( $check % 2 == 0 ) ? 'row1' : 'row2', + 'EVENT_ID' => stripslashes( $row['event_id'] ), + 'SUBJECT' => stripslashes( $row['subject'] ), + 'DATE' => my_dateformat( $row['stamp'], $block_datefmt ), + 'END_DATE' => my_dateformat( $row['eventspan'], $block_datefmt, 1 ), + 'DESC' => stripslashes( $row['description'] ), + 'BBTEXT' => my_decode_bbtext( $row['description'], $row['bbcode_uid'] ), + 'AUTHOR' => stripslashes( $row['username'] ) ) + ); $check++; } *************** *** 103,115 **** $template->assign_block_vars( 'no_events', array( 'NO_EVENTS' => $lang["No events"] ) ); } ! $template->assign_vars( array( 'BLOCK_SIZE' => $block_size, ! 'L_TITLE' => ( $block_title == '' ? $lang['Calendar_Events'] : $block_title ) ) ! ); $template->pparse( 'body' ); // -------------------------------------------------------------------------------- ! } //if( $caluser > 0 ) // -------------------------------------------------------------------------------- ! unset( $caluser ); //MX001: added so more than one block per page may exist. ! ! ?> \ No newline at end of file --- 108,120 ---- $template->assign_block_vars( 'no_events', array( 'NO_EVENTS' => $lang["No events"] ) ); } ! $template->assign_vars( array( ! 'BLOCK_SIZE' => $block_size, ! 'L_TITLE' => ( $block_title == '' ? $lang['Calendar_Events'] : $block_title ) ) ! ); ! $template->pparse( 'body' ); // -------------------------------------------------------------------------------- ! } // // -------------------------------------------------------------------------------- ! unset( $caluser ); ?> \ No newline at end of file Index: db_uninstall.php =================================================================== RCS file: /cvsroot/mxbb/mx_calsnails/db_uninstall.php,v retrieving revision 1.12 retrieving revision 1.13 diff -C2 -d -r1.12 -r1.13 *** db_uninstall.php 2 May 2006 23:25:58 -0000 1.12 --- db_uninstall.php 29 Jun 2006 13:39:03 -0000 1.13 *************** *** 30,38 **** } ! $sql = array( "DROP TABLE " . $mx_table_prefix . "callite_config ", ! "DROP TABLE " . $mx_table_prefix . "callite_events" ! ! ); echo "<br /><br />"; --- 30,37 ---- } ! $sql = array( ! "DROP TABLE " . $mx_table_prefix . "callite_config ", "DROP TABLE " . $mx_table_prefix . "callite_events" ! ); echo "<br /><br />"; *************** *** 41,44 **** echo "<tr><td class=\"row1\" align=\"left\"><span class=\"gen\">" . mx_do_install_upgrade( $sql ) . "</span></td></tr>"; echo "</table><br />"; - ?> \ No newline at end of file --- 40,42 ---- Index: db_upgrade.php =================================================================== RCS file: /cvsroot/mxbb/mx_calsnails/db_upgrade.php,v retrieving revision 1.13 retrieving revision 1.14 diff -C2 -d -r1.13 -r1.14 *** db_upgrade.php 2 May 2006 23:25:58 -0000 1.13 --- db_upgrade.php 29 Jun 2006 13:39:03 -0000 1.14 *************** *** 30,34 **** } ! $mx_module_version = '2.0.0'; $mx_module_copy = 'Original phpBB <i>Calendar LITE</i> MOD by <a href="http://www.snailsource.com/" target="_blank">Martin</a> :: Adapted for mxBB by <a href="http://www.phpmix.com" target="_blank">Markus</a> & <a href="http://www.mxbb-portal.com" target="_blank">Jon</a>'; --- 30,34 ---- } ! $mx_module_version = '2.8.0'; $mx_module_copy = 'Original phpBB <i>Calendar LITE</i> MOD by <a href="http://www.snailsource.com/" target="_blank">Martin</a> :: Adapted for mxBB by <a href="http://www.phpmix.com" target="_blank">Markus</a> & <a href="http://www.mxbb-portal.com" target="_blank">Jon</a>'; Index: db_install.php =================================================================== RCS file: /cvsroot/mxbb/mx_calsnails/db_install.php,v retrieving revision 1.20 retrieving revision 1.21 diff -C2 -d -r1.20 -r1.21 *** db_install.php 2 May 2006 23:25:58 -0000 1.20 --- db_install.php 29 Jun 2006 13:39:03 -0000 1.21 *************** *** 30,34 **** } ! $mx_module_version = '2.0.0'; $mx_module_copy = 'Original phpBB <i>Calendar LITE</i> MOD by <a href="http://www.snailsource.com/" target="_blank">Martin</a> :: Adapted for mxBB by <a href="http://www.phpmix.com" target="_blank">Markus</a> & <a href="http://www.mxbb-portal.com" target="_blank">Jon</a>'; --- 30,34 ---- } ! $mx_module_version = '2.8.0'; $mx_module_copy = 'Original phpBB <i>Calendar LITE</i> MOD by <a href="http://www.snailsource.com/" target="_blank">Martin</a> :: Adapted for mxBB by <a href="http://www.phpmix.com" target="_blank">Markus</a> & <a href="http://www.mxbb-portal.com" target="_blank">Jon</a>'; Index: mx_calendar_events.php =================================================================== RCS file: /cvsroot/mxbb/mx_calsnails/mx_calendar_events.php,v retrieving revision 1.19 retrieving revision 1.20 diff -C2 -d -r1.19 -r1.20 *** mx_calendar_events.php 17 Jun 2006 20:45:55 -0000 1.19 --- mx_calendar_events.php 29 Jun 2006 13:39:03 -0000 1.20 *************** *** 44,49 **** define( 'CALRANGE_NEXT_MONTH', 'next month' ); // Check parameters: assign default values if the module is not correctly installed. ! if ( empty( $block_title ) ) { --- 44,50 ---- define( 'CALRANGE_NEXT_MONTH', 'next month' ); + // // Check parameters: assign default values if the module is not correctly installed. ! // if ( empty( $block_title ) ) { *************** *** 67,71 **** --- 68,74 ---- } + // // Get Calsnails target block + // $cal_block_id = $mx_block->get_parameters( 'target_block' ); $cal_page_id = get_page_id( $cal_block_id ); *************** *** 74,79 **** $cal_page_filter = $cal_block_config[$cal_block_id]['cal_filter']['parameter_value'] == 'TRUE'; // Security Check ! if ( isset( $HTTP_GET_VARS['caluser'] ) || isset( $HTTP_POST_VARS['caluser'] ) || isset( $caluser ) ) { --- 77,83 ---- $cal_page_filter = $cal_block_config[$cal_block_id]['cal_filter']['parameter_value'] == 'TRUE'; + // // Security Check ! // if ( isset( $HTTP_GET_VARS['caluser'] ) || isset( $HTTP_POST_VARS['caluser'] ) || isset( $caluser ) ) { *************** *** 88,91 **** --- 92,96 ---- $caluser = ( $userdata['user_id'] == ANONYMOUS ? $cal_config['allow_anon'] : $cal_config['allow_user_default'] ); } + // -------------------------------------------------------------------------------- // Check if the user can see. Otherwise, nothing to do. *************** *** 97,101 **** // Compute date range depending on block parameters. - switch ( $events_range ) { --- 102,105 ---- *************** *** 139,144 **** list( $end_yy, $end_mm, $end_dd ) = explode( '-', create_date( 'Y-m-j', $end_time, $cal_timezone ) ); // Build the query (note use of fixed condition: valid = 'yes'). ! $sql = "SELECT * FROM " . CALLITE_EVENTS_TABLE . " WHERE valid = 'yes' AND "; --- 143,149 ---- list( $end_yy, $end_mm, $end_dd ) = explode( '-', create_date( 'Y-m-j', $end_time, $cal_timezone ) ); + // // Build the query (note use of fixed condition: valid = 'yes'). ! // $sql = "SELECT * FROM " . CALLITE_EVENTS_TABLE . " WHERE valid = 'yes' AND "; *************** *** 156,161 **** } // Loop through Calendar Events... ! $today = create_date( 'Y-m-d', time(), $cal_timezone ); $check = 0; --- 161,167 ---- } + // // Loop through Calendar Events... ! // $today = create_date( 'Y-m-d', time(), $cal_timezone ); $check = 0; *************** *** 215,220 **** $db->sql_freeresult($result); // Do we get any event? Do we need to enable scrollbars? ! if ( $check == 0 ) { --- 221,227 ---- $db->sql_freeresult($result); + // // Do we get any event? Do we need to enable scrollbars? ! // if ( $check == 0 ) { *************** *** 266,271 **** } // Setup common template vars and display the block. ! $template->assign_vars( array( 'BLOCK_SIZE' => $block_size, 'EVENTS_LABEL' => $events_label, --- 273,279 ---- } + // // Setup common template vars and display the block. ! // $template->assign_vars( array( 'BLOCK_SIZE' => $block_size, 'EVENTS_LABEL' => $events_label, *************** *** 278,285 **** $template->pparse( 'body' ); // -------------------------------------------------------------------------------- ! } //if( $caluser > 0 ) // -------------------------------------------------------------------------------- ! unset( $caluser ); //MX001: added so more than one block per page may exist. ! ! ?> \ No newline at end of file --- 286,291 ---- $template->pparse( 'body' ); // -------------------------------------------------------------------------------- ! } // // -------------------------------------------------------------------------------- ! unset( $caluser ); ?> \ No newline at end of file Index: calendar.php =================================================================== RCS file: /cvsroot/mxbb/mx_calsnails/calendar.php,v retrieving revision 1.25 retrieving revision 1.26 diff -C2 -d -r1.25 -r1.26 *** calendar.php 29 May 2006 15:38:05 -0000 1.25 --- calendar.php 29 Jun 2006 13:39:03 -0000 1.26 *************** *** 37,41 **** #################################################################*/ // -------------------------------------------------- - // +MX001: Begin if( !defined('IN_PORTAL') || !is_object($mx_block)) --- 37,40 ---- *************** *** 44,49 **** } // Common Includes and Read Calendar Lite Settings ! include_once( $module_root_path . 'includes/mx_common.' . $phpEx ); --- 43,49 ---- } + // // Common Includes and Read Calendar Lite Settings ! // include_once( $module_root_path . 'includes/mx_common.' . $phpEx ); *************** *** 59,65 **** $cal_filter = $mx_block->get_parameters( 'cal_filter' ) == 'TRUE' ; $cal_mod_group = $mx_block->get_parameters( 'cal_mod_group' ); - // echo($cal_auth_all.$cal_auth_reg.$cal_filter); // Get Calsnails target block $cal_block_id = $mx_block->get_parameters( 'target_block' ); $cal_page_id = get_page_id( $cal_block_id ); --- 59,66 ---- $cal_filter = $mx_block->get_parameters( 'cal_filter' ) == 'TRUE' ; $cal_mod_group = $mx_block->get_parameters( 'cal_mod_group' ); + // // Get Calsnails target block + // $cal_block_id = $mx_block->get_parameters( 'target_block' ); $cal_page_id = get_page_id( $cal_block_id ); *************** *** 70,100 **** } // Get the current MX page. ! $page_id = ( !empty( $HTTP_POST_VARS['page'] ) ) ? $HTTP_POST_VARS['page'] : $HTTP_GET_VARS['page']; - // -MX001: End - // -------------------------------------------------- - // Set $phpbb_root_path to location of phpBB2 root directory. - // MX002: $phpbb_root_path = "./"; - // MX002: include_once($phpbb_root_path . 'cal_settings.php'); /*########################################## ## STOP # ## DO NOT MODIFY ANYTHING BELOW THIS LINE # ##########################################*/ // Security Check if ( isset( $HTTP_GET_VARS['caluser'] ) || isset( $HTTP_POST_VARS['caluser'] ) || isset( $caluser ) ) { // Failed the test... Someone tried to spoof as a user. ! die( "Hacking attempt" ); //MX001: added ! } ! // +MX001 ! /* ! else { ! // Passed. ! define('IN_PHPBB', true); } ! */ ! // -MX001 $params = array( 'sid' => 'sid', 'id' => 'id', --- 71,93 ---- } + // // Get the current MX page. ! // $page_id = ( !empty( $HTTP_POST_VARS['page'] ) ) ? $HTTP_POST_VARS['page'] : $HTTP_GET_VARS['page']; /*########################################## ## STOP # ## DO NOT MODIFY ANYTHING BELOW THIS LINE # ##########################################*/ + + // // Security Check + // if ( isset( $HTTP_GET_VARS['caluser'] ) || isset( $HTTP_POST_VARS['caluser'] ) || isset( $caluser ) ) { // Failed the test... Someone tried to spoof as a user. ! die( "Hacking attempt" ); } ! $params = array( 'sid' => 'sid', 'id' => 'id', *************** *** 126,169 **** } } ! // unset($HTTP_POST_VARS); ! // unset($HTTP_GET_VARS); ! // MX004: $thisscript = basename(__FILE__); $thisscript = $module_root_path . basename( __FILE__ ); - // connect to phpbb - // +MX003 - // include_once($phpbb_root_path . 'extension.inc'); - // include_once($phpbb_root_path . 'common.'.$phpEx); - // include_once($phpbb_root_path . 'includes/bbcode.'.$phpEx); - // include_once($phpbb_root_path . 'includes/functions.'.$phpEx); - // -MX003 - // Start session management - // MX001: $userdata = session_pagestart($user_ip, PAGE_INDEX, $session_length); - // MX001: init_userprefs($userdata); - // +MX006 - // define('CAL_TABLE', ($table_prefix . $tablename)); - // define('CAL_CONFIG', ($table_prefix . cal_config)); - // -MX006 - // -------------------------------------------------- - // +MX016 - /* - // Get Calendar Settings from Cal_config table - $cal_config = array(); - $sql = "SELECT * FROM ".CAL_CONFIG; - if(!$result = $db->sql_query($sql)) - { - mx_message_die(GENERAL_ERROR, "Couldn't query calendar config table", "", __LINE__, __FILE__, $sql); - } - else - { - while( $row = $db->sql_fetchrow($result) ) - { - $cal_config[$row['config_name']] = $row['config_value']; - } - } - $db->sql_freeresult($result); - // End of Calendar settings - */ - // -MX016 // -------------------------------------------------- // Interim days id to help with transfer to $lang['datetime'] format. --- 119,125 ---- } } ! $thisscript = $module_root_path . basename( __FILE__ ); // -------------------------------------------------- // Interim days id to help with transfer to $lang['datetime'] format. *************** *** 177,181 **** $langdays[6] = $lang['datetime']['Saturday']; $langdays[7] = $lang['datetime']['Sunday']; // Repeated to cover a Monday start ! // +MX014 if ( $cal_mode_mini ) { --- 133,137 ---- $langdays[6] = $lang['datetime']['Saturday']; $langdays[7] = $lang['datetime']['Sunday']; // Repeated to cover a Monday start ! if ( $cal_mode_mini ) { *************** *** 189,198 **** $langdays[7] = $langdays[0]; } ! // -MX014 // Add EDIT block nav // $is_auth_ary = array(); $is_cal_moderator = !$cal_mode_mini ? mx_is_group_member( $cal_mod_group ) : false; // Set Users permissions. if ( $userdata['user_level'] == ADMIN || $is_cal_moderator ) { --- 145,158 ---- $langdays[7] = $langdays[0]; } ! ! // // Add EDIT block nav // $is_auth_ary = array(); + // $is_cal_moderator = !$cal_mode_mini ? mx_is_group_member( $cal_mod_group ) : false; + // // Set Users permissions. + // if ( $userdata['user_level'] == ADMIN || $is_cal_moderator ) { *************** *** 201,209 **** else { - // MX999: $test = $userdata['user_id']; - // MX999: $caluser = calendarperm($test); // Set the user level for the user. - // +MX015 - // $caluser = ($userdata['user_id'] == '-1' ? $cal_config['allow_anon'] : $cal_config['allow_user_default']); - // -MX015 $caluser = ( $userdata['user_id'] == '-1' ? $cal_auth_all : $cal_auth_reg ); } --- 161,164 ---- *************** *** 217,227 **** $lvd = "Not Logged In"; } ! // +MX005 if ( $generate_headers ) { include( $mx_root_path . 'includes/page_header.' . $phpEx ); } ! // -MX005 // Set Calendar Home URL (used in all templates) $homeurl = append_sid( this_mxurl() ); --- 172,184 ---- $lvd = "Not Logged In"; } ! if ( $generate_headers ) { include( $mx_root_path . 'includes/page_header.' . $phpEx ); } ! ! // // Set Calendar Home URL (used in all templates) + // $homeurl = append_sid( this_mxurl() ); *************** *** 245,249 **** } // -------------------------------------------------- - // +MX015 // Public Access check --- 202,205 ---- *************** *** 254,259 **** // } - // MX015: Avoid sending an auth error for MINI mode. - if ( !$cal_mode_mini ) { --- 210,213 ---- *************** *** 273,277 **** } - // -MX015 // -------------------------------------------------- // Default date --- 227,230 ---- *************** *** 288,291 **** --- 241,245 ---- } */ + // FIX: Time off 1 day if ( !$day ) *************** *** 307,311 **** $lastday++; } ! // +MX014 if ( $cal_mode_mini ) { --- 261,265 ---- $lastday++; } ! if ( $cal_mode_mini ) { *************** *** 324,328 **** { display(); ! } //MX015: added $caluser condition elseif ( $action == 'Delete_marked' && $caluser >= 4 ) { --- 278,282 ---- { display(); ! } elseif ( $action == 'Delete_marked' && $caluser >= 4 ) { *************** *** 340,349 **** { defaultview( $todaycolor ); ! } //MX015: added $caluser condition } - // -MX014 - unset( $caluser ); //MX001: added so more than one block per page may exist. ! // +MX005 if ( $generate_headers ) { --- 294,302 ---- { defaultview( $todaycolor ); ! } } ! unset( $caluser ); ! if ( $generate_headers ) { *************** *** 351,360 **** exit; } ! // -MX005 // ------------------------------------------------------------------------------------------ // [ FUNCTIONS ] // ------------------------------------------------------------------------------------------ // -------------------------------------------------- - // +MX021: Begin if ( function_exists( 'this_mxurl' ) ) --- 304,312 ---- exit; } ! // ------------------------------------------------------------------------------------------ // [ FUNCTIONS ] // ------------------------------------------------------------------------------------------ // -------------------------------------------------- if ( function_exists( 'this_mxurl' ) ) *************** *** 363,370 **** } - // -MX021: End // -------------------------------------------------- // -------------------------------------------------- - // +MX007: Begin - ?> \ No newline at end of file --- 315,319 ---- |
|
From: Jon O. <jon...@us...> - 2006-06-29 13:39:06
|
Update of /cvsroot/mxbb/mx_calsnails/includes In directory sc8-pr-cvs7.sourceforge.net:/tmp/cvs-serv4127/modules/mx_calsnails/includes Modified Files: cal_functions.php mx_common.php Log Message: Code cleanup Index: cal_functions.php =================================================================== RCS file: /cvsroot/mxbb/mx_calsnails/includes/cal_functions.php,v retrieving revision 1.5 retrieving revision 1.6 diff -C2 -d -r1.5 -r1.6 *** cal_functions.php 25 Jun 2006 21:53:26 -0000 1.5 --- cal_functions.php 29 Jun 2006 13:39:03 -0000 1.6 *************** *** 41,53 **** } - // -MX007: End - // -------------------------------------------------- function validate() { // Start of MOD function (validate untrusted events) global $thisscript, $phpbb_root_path, $phpEx, $db, $action, $template, $id, $day, $month, $year, $userdata, $lang, $config_footer, $footer, $caluser, ! $block_size, // MX001 [...1117 lines suppressed...] global $lang, $caluser; + if ( $caluser >= 5 ) { *************** *** 1242,1245 **** --- 1279,1283 ---- { global $lang, $caluser; + if ( $caluser >= 4 ) { *************** *** 1268,1271 **** --- 1306,1310 ---- { global $lang, $caluser, $block_id; + // Next Month $button_add = "<form method=post action='$url'><td>"; Index: mx_common.php =================================================================== RCS file: /cvsroot/mxbb/mx_calsnails/includes/mx_common.php,v retrieving revision 1.15 retrieving revision 1.16 diff -C2 -d -r1.15 -r1.16 *** mx_common.php 26 Jun 2006 21:33:17 -0000 1.15 --- mx_common.php 29 Jun 2006 13:39:03 -0000 1.16 *************** *** 22,28 **** if ( !defined( 'DB_INSTALL' ) ) { ! // Get Calendar Settings from Cal_config table ! $cal_config = array(); --- 22,28 ---- if ( !defined( 'DB_INSTALL' ) ) { ! // // Get Calendar Settings from Cal_config table ! // $cal_config = array(); *************** *** 55,59 **** // a) Martin's mydateformat() does not translate weekdays. // b) Solve the phpBB collision with $lang['datetime']['May']. - function my_dateformat( $thisdate, $dateformat = 'd M Y G:i', $span = 0 ) { --- 55,58 ---- *************** *** 155,158 **** return $woy; } - ?> \ No newline at end of file --- 154,156 ---- |
|
From: Jon O. <jon...@us...> - 2006-06-29 13:39:06
|
Update of /cvsroot/mxbb/mx_calsnails/admin In directory sc8-pr-cvs7.sourceforge.net:/tmp/cvs-serv4127/modules/mx_calsnails/admin Modified Files: admin_calendar.php Log Message: Code cleanup Index: admin_calendar.php =================================================================== RCS file: /cvsroot/mxbb/mx_calsnails/admin/admin_calendar.php,v retrieving revision 1.12 retrieving revision 1.13 diff -C2 -d -r1.12 -r1.13 *** admin_calendar.php 2 May 2006 23:25:58 -0000 1.12 --- admin_calendar.php 29 Jun 2006 13:39:02 -0000 1.13 *************** *** 9,13 **** */ - // MX001: define('IN_PHPBB', 1); define( 'IN_PORTAL', true ); --- 9,12 ---- *************** *** 15,38 **** { $filename = basename( __FILE__ ); - // MX002 $module['Portal CalSnails Lite']['Settings'] = 'modules/mx_calsnails/admin/' . $filename; return; } - // -------------------------------------------------- - // MX003: Begin - - /* ========== * ========== * ========== * - global $db; - // - // Load default header - // - $phpbb_root_path = "../"; - $phpEx = substr(strrchr(__FILE__, '.'), 1); - require('pagestart.' . $phpEx); - - require($phpbb_root_path . 'language/lang_' . $board_config['default_lang'] . '/lang_main.' . $phpEx); - $page_title = $lang['Config_Cal']; - $caltable = $table_prefix . "cal_config"; - * ========== * ========== * ========== */ $mx_root_path = '../../../'; --- 14,20 ---- *************** *** 46,51 **** include_once( $mx_root_path . 'admin/page_header_admin.' . $phpEx ); - // MX003: End - // -------------------------------------------------- $sql = "SELECT * FROM " . $caltable; if ( !$result = $db->sql_query( $sql ) ) --- 28,31 ---- *************** *** 82,86 **** --- 62,69 ---- } } + + // // Build Week Start select box + // $week_start_select = "<select name='week_start'>"; $week_start_select .= "<option value='0' "; *************** *** 100,105 **** $show_headers_yes = ( $new['show_headers'] ) ? "checked=\"checked\"" : ""; $show_headers_no = ( !$new['show_headers'] ) ? "checked=\"checked\"" : ""; - // ---------- - // +MX005 function get_cal_levels( $field ) --- 83,86 ---- *************** *** 132,184 **** $s_cal_type = get_cal_levels( 'allow_user_default' ); ! // -MX005 ! // ---------- ! $template->set_filenames( array( "body" => "admin/calendar_config_body.tpl" ) ! ); ! ! $template->assign_vars( array( "S_CONFIG_ACTION" => append_sid( "admin_calendar.$phpEx" ), ! "L_YES" => $lang['Yes'], ! "L_NO" => $lang['No'], ! "L_CONFIGURATION_TITLE" => $lang['Config_Calendar'], ! "L_GENERAL_SETTINGS" => $lang['Config_Calendar'], ! "L_CONFIGURATION_EXPLAIN" => $lang['Config_Calendar_explain'], ! "L_WEEK_START" => $lang['week_start'], ! "L_SUBJECT_LENGTH" => $lang['subject_length'], ! "L_SUBJECT_LENGTH_EXPLAIN" => $lang['subject_length_explain'], ! "L_ALLOW_ANON" => $lang['allow_anon'], ! "L_ALLOW_USER_POST" => $lang['allow_user_post'], ! "L_ALLOW_ANON_DEFAULT" => $lang['allow_anon_post_default'], // MX005: added ! "L_ALLOW_USER_DEFAULT" => $lang['allow_user_post_default'], ! "L_ALLOW_OLD" => $lang['allow_old'], ! "L_ALLOW_OLD_EXPLAIN" => $lang['allow_old_explain'], ! "L_SHOW_HEADERS" => $lang['show_headers'], ! "L_DATE_FORMAT" => $lang['Date_format'], ! "L_DATE_FORMAT_EXPLAIN" => $lang['cal_date_explain'], ! "L_SUBMIT" => $lang['Submit'], ! "L_RESET" => $lang['Reset'], ! "WEEK_START_SELECT" => $week_start_select, ! "SUBJECT_LENGTH" => $new['subject_length'], ! "SCIPT_PATH" => $new['cal_script_path'], ! "S_ALLOW_ANON_YES" => $allow_anon_yes, ! "S_ALLOW_ANON_NO" => $allow_anon_no, ! "S_ALLOW_USER_POST_YES" => $allow_user_post_yes, ! "S_ALLOW_USER_POST_NO" => $allow_user_post_no, ! "S_ALLOW_ANON_DEFAULT" => $s_cal_anon, // MX005: added ! "S_ALLOW_USER_DEFAULT" => $s_cal_type, ! "S_ALLOW_OLD_YES" => $allow_old_yes, ! "S_ALLOW_OLD_NO" => $allow_old_no, ! "S_SHOW_HEADERS_YES" => $show_headers_yes, ! "S_SHOW_HEADERS_NO" => $show_headers_no, ! "CAL_DATEFORMAT" => $new['cal_dateformat'] ) ! ); $template->pparse( "body" ); - // MX004: include('./page_footer_admin.'.$phpEx); include_once( $mx_root_path . 'admin/page_footer_admin.' . $phpEx ); - ?> \ No newline at end of file --- 113,160 ---- $s_cal_type = get_cal_levels( 'allow_user_default' ); ! $template->set_filenames( array( "body" => "admin/calendar_config_body.tpl" ) ); ! $template->assign_vars( array( ! "S_CONFIG_ACTION" => append_sid( "admin_calendar.$phpEx" ), ! "L_YES" => $lang['Yes'], ! "L_NO" => $lang['No'], ! "L_CONFIGURATION_TITLE" => $lang['Config_Calendar'], ! "L_GENERAL_SETTINGS" => $lang['Config_Calendar'], ! "L_CONFIGURATION_EXPLAIN" => $lang['Config_Calendar_explain'], ! "L_WEEK_START" => $lang['week_start'], ! "L_SUBJECT_LENGTH" => $lang['subject_length'], ! "L_SUBJECT_LENGTH_EXPLAIN" => $lang['subject_length_explain'], ! "L_ALLOW_ANON" => $lang['allow_anon'], ! "L_ALLOW_USER_POST" => $lang['allow_user_post'], ! "L_ALLOW_ANON_DEFAULT" => $lang['allow_anon_post_default'], // MX005: added ! "L_ALLOW_USER_DEFAULT" => $lang['allow_user_post_default'], ! "L_ALLOW_OLD" => $lang['allow_old'], ! "L_ALLOW_OLD_EXPLAIN" => $lang['allow_old_explain'], ! "L_SHOW_HEADERS" => $lang['show_headers'], ! "L_DATE_FORMAT" => $lang['Date_format'], ! "L_DATE_FORMAT_EXPLAIN" => $lang['cal_date_explain'], ! "L_SUBMIT" => $lang['Submit'], ! "L_RESET" => $lang['Reset'], ! "WEEK_START_SELECT" => $week_start_select, ! "SUBJECT_LENGTH" => $new['subject_length'], ! "SCIPT_PATH" => $new['cal_script_path'], ! "S_ALLOW_ANON_YES" => $allow_anon_yes, ! "S_ALLOW_ANON_NO" => $allow_anon_no, ! "S_ALLOW_USER_POST_YES" => $allow_user_post_yes, ! "S_ALLOW_USER_POST_NO" => $allow_user_post_no, ! "S_ALLOW_ANON_DEFAULT" => $s_cal_anon, // MX005: added ! "S_ALLOW_USER_DEFAULT" => $s_cal_type, ! "S_ALLOW_OLD_YES" => $allow_old_yes, ! "S_ALLOW_OLD_NO" => $allow_old_no, ! "S_SHOW_HEADERS_YES" => $show_headers_yes, ! "S_SHOW_HEADERS_NO" => $show_headers_no, ! "CAL_DATEFORMAT" => $new['cal_dateformat'] ! )); $template->pparse( "body" ); include_once( $mx_root_path . 'admin/page_footer_admin.' . $phpEx ); ?> \ No newline at end of file |
|
From: Jon O. <jon...@us...> - 2006-06-29 13:14:52
|
Update of /cvsroot/mxbb/mx_pafiledb/pafiledb/modules In directory sc8-pr-cvs7.sourceforge.net:/tmp/cvs-serv25056/modules/mx_pafiledb/pafiledb/modules Modified Files: pa_post_comment.php Log Message: Selvens fix for finding bbcode faq info when posting Index: pa_post_comment.php =================================================================== RCS file: /cvsroot/mxbb/mx_pafiledb/pafiledb/modules/pa_post_comment.php,v retrieving revision 1.17 retrieving revision 1.18 diff -C2 -d -r1.17 -r1.18 *** pa_post_comment.php 28 Jun 2006 21:44:04 -0000 1.17 --- pa_post_comment.php 29 Jun 2006 13:14:48 -0000 1.18 *************** *** 285,289 **** $pafiledb_template->assign_vars( array( 'HTML_STATUS' => $html_status, ! 'BBCODE_STATUS' => sprintf( $bbcode_status, '<a href="' . append_sid( "faq.$phpEx?mode=bbcode" ) . '" target="_phpbbcode">', '</a>' ), 'SMILIES_STATUS' => $smilies_status, 'LINKS_STATUS' => $links_status, --- 285,289 ---- $pafiledb_template->assign_vars( array( 'HTML_STATUS' => $html_status, ! 'BBCODE_STATUS' => sprintf($bbcode_status, '<a href="' . PHPBB_URL . append_sid("faq.$phpEx?mode=bbcode") . '" target="_phpbbcode">', '</a>'), 'SMILIES_STATUS' => $smilies_status, 'LINKS_STATUS' => $links_status, |
|
From: Jon O. <jon...@us...> - 2006-06-29 13:14:26
|
Update of /cvsroot/mxbb/mx_kb/kb/modules In directory sc8-pr-cvs7.sourceforge.net:/tmp/cvs-serv24935/modules/mx_kb/kb/modules Modified Files: kb_post.php kb_post_comment.php Log Message: Selvens fix for finding bbcode faq info when posting Index: kb_post.php =================================================================== RCS file: /cvsroot/mxbb/mx_kb/kb/modules/kb_post.php,v retrieving revision 1.6 retrieving revision 1.7 diff -C2 -d -r1.6 -r1.7 *** kb_post.php 25 Jun 2006 21:55:12 -0000 1.6 --- kb_post.php 29 Jun 2006 13:14:20 -0000 1.7 *************** *** 425,429 **** 'HTML_STATUS' => $html_status, ! 'BBCODE_STATUS' => sprintf( $bbcode_status, '<a href="' . append_sid( "faq.$phpEx?mode=bbcode" ) . '" target="_phpbbcode">', '</a>' ), 'SMILIES_STATUS' => $smilies_status, 'LINKS_STATUS' => $links_status, --- 425,429 ---- 'HTML_STATUS' => $html_status, ! 'BBCODE_STATUS' => sprintf($bbcode_status, '<a href="' . PHPBB_URL . append_sid("faq.$phpEx?mode=bbcode") . '" target="_phpbbcode">', '</a>'), 'SMILIES_STATUS' => $smilies_status, 'LINKS_STATUS' => $links_status, Index: kb_post_comment.php =================================================================== RCS file: /cvsroot/mxbb/mx_kb/kb/modules/kb_post_comment.php,v retrieving revision 1.6 retrieving revision 1.7 diff -C2 -d -r1.6 -r1.7 *** kb_post_comment.php 28 Jun 2006 21:43:32 -0000 1.6 --- kb_post_comment.php 29 Jun 2006 13:14:20 -0000 1.7 *************** *** 288,292 **** $template->assign_vars( array( 'HTML_STATUS' => $html_status, ! 'BBCODE_STATUS' => sprintf( $bbcode_status, '<a href="' . append_sid( "faq.$phpEx?mode=bbcode" ) . '" target="_phpbbcode">', '</a>' ), 'SMILIES_STATUS' => $smilies_status, 'LINKS_STATUS' => $links_status, --- 288,292 ---- $template->assign_vars( array( 'HTML_STATUS' => $html_status, ! 'BBCODE_STATUS' => sprintf($bbcode_status, '<a href="' . PHPBB_URL . append_sid("faq.$phpEx?mode=bbcode") . '" target="_phpbbcode">', '</a>'), 'SMILIES_STATUS' => $smilies_status, 'LINKS_STATUS' => $links_status, |
|
From: Jon O. <jon...@us...> - 2006-06-29 13:14:23
|
Update of /cvsroot/mxbb/mx_kb In directory sc8-pr-cvs7.sourceforge.net:/tmp/cvs-serv24935/modules/mx_kb Modified Files: KnowledgeBase.pak Log Message: Selvens fix for finding bbcode faq info when posting Index: KnowledgeBase.pak =================================================================== RCS file: /cvsroot/mxbb/mx_kb/KnowledgeBase.pak,v retrieving revision 1.9 retrieving revision 1.10 diff -C2 -d -r1.9 -r1.10 *** KnowledgeBase.pak 28 Jun 2006 13:58:07 -0000 1.9 --- KnowledgeBase.pak 29 Jun 2006 13:14:19 -0000 1.10 *************** *** 1,29 **** ! module=+:41=+:Knowledge Base=+:modules/mx_kb/=+:Knowledge Base module=+:1 New_function=+:---------------------------=+:0=+:0=+:0=+:0=+:0 ! function=+:41=+:42=+:KB=+:Knowledge Base Module=+:kb.php=+: ! parameter=+:42=+:79=+:kb_type_select=+:kb_type_select=+:=+:=+:0 parameter=+:0=+:0=+:0=+:endoflist=+:0=+:0 ! block=+:=+:Demo - KB=+:Demo block=+:42=+:0=+:5=+:0=+:0=+:0=+:0=+:1=+:1 New_function=+:---------------------------=+:0=+:0=+:0=+:0=+:0 ! function=+:41=+:96=+:Article_reader=+:Block to display articles only. No category navigation. To be used with newssuite.=+:kb_article_reader.php=+: ! parameter=+:96=+:302=+:default_article_id=+:Number=+:1=+:=+:0 ! parameter=+:96=+:301=+:kb_type_select=+:kb_type_select=+:array('init'=>'1')=+:=+:0 parameter=+:0=+:0=+:0=+:endoflist=+:0=+:0 ! block=+:=+:Demo - Article_reader=+:Demo block=+:96=+:0=+:5=+:0=+:0=+:0=+:0=+:1=+:1 ! function=+:0=+:0=+:0=+:endoflist=+:0=+:0 New_function=+:---------------------------=+:0=+:0=+:0=+:0=+:0 ! function=+:30=+:31=+:Last Articles=+:KB Last Articles Function=+:kb_last_article.php=+: ! parameter=+:31=+:21=+:Last_Article_Align=+:Values=+:left=+:=+:0 ! parameter=+:31=+:39=+:Last_Article_Display_Author=+:Boolean=+:FALSE=+:=+:0 ! parameter=+:31=+:18=+:Last_Article_Display_Date=+:Boolean=+:TRUE=+:=+:0 ! parameter=+:31=+:22=+:Last_Article_Display_Cat=+:Boolean=+:TRUE=+:=+:0 ! parameter=+:31=+:40=+:Last_Article_Display_Icon_View=+:Boolean=+:TRUE=+:=+:0 ! parameter=+:31=+:38=+:Last_Article_Display_Last_Author=+:Boolean=+:TRUE=+:=+:0 ! parameter=+:31=+:37=+:Last_Article_Cat=+:Function=+:=+:get_list_multiple("{parameter_id}[]", FORUMS_TABLE, 'forum_id', 'forum_name', "{parameter_value}", TRUE)=+:0 ! parameter=+:31=+:17=+:Last_Article_Number_Title=+:Number=+:15=+:=+:0 ! parameter=+:31=+:20=+:Last_Article_Target=+:Values=+:_blank=+:=+:0 ! parameter=+:31=+:19=+:Last_Article_Title_Length=+:Number=+:30=+:=+:0 ! parameter=+:31=+:95=+:article_filter_date=+:Function=+:5=+:get_list_static("{parameter_id}[]",array("no limit", "1 day", "2 days", "3 days", "1 week", "2 weeks", "3 weeks", "1 month", "2 months", "3 months", "6 months", "1 year"),"{parameter_value}")=+:0 parameter=+:0=+:0=+:0=+:endoflist=+:0=+:0 ! block=+:=+:Demo - Last Articles=+:Demo block=+:31=+:0=+:5=+:0=+:0=+:0=+:0=+:1=+:1 ! function=+:0=+:0=+:0=+:endoflist=+:0=+:0 \ No newline at end of file --- 1,29 ---- ! module=+:55=+:Knowledge Base=+:modules/mx_kb/=+:Knowledge Base module=+:1 New_function=+:---------------------------=+:0=+:0=+:0=+:0=+:0 ! function=+:55=+:61=+:KB=+:Knowledge Base Module=+:kb.php=+: ! parameter=+:61=+:118=+:kb_type_select=+:kb_type_select=+:=+:=+:0 parameter=+:0=+:0=+:0=+:endoflist=+:0=+:0 ! block=+:=+:Demo - KB=+:Demo block=+:61=+:0=+:5=+:0=+:0=+:0=+:0=+:1=+:1 New_function=+:---------------------------=+:0=+:0=+:0=+:0=+:0 ! function=+:55=+:62=+:Article_reader=+:Block to display articles only. No category navigation. To be used with newssuite.=+:kb_article_reader.php=+: ! parameter=+:62=+:119=+:default_article_id=+:Number=+:1=+:=+:0 ! parameter=+:62=+:120=+:kb_type_select=+:kb_type_select=+:array('init'=>'1')=+:=+:0 parameter=+:0=+:0=+:0=+:endoflist=+:0=+:0 ! block=+:=+:Demo - Article_reader=+:Demo block=+:62=+:0=+:5=+:0=+:0=+:0=+:0=+:1=+:1 New_function=+:---------------------------=+:0=+:0=+:0=+:0=+:0 ! function=+:55=+:63=+:Last Articles=+:KB Last Articles Function=+:kb_last_article.php=+: ! parameter=+:63=+:131=+:article_filter_date=+:Function=+:5=+:get_list_static("{parameter_id}[]",array("no limit", "1 day", "2 days", "3 days", "1 week", "2 weeks", "3 weeks", "1 month", "2 months", "3 months", "6 months", "1 year"),"{parameter_value}")=+:0 ! parameter=+:63=+:121=+:Last_Article_Align=+:Values=+:left=+:=+:0 ! parameter=+:63=+:127=+:Last_Article_Cat=+:kb_type_select=+:array()=+:=+:0 ! parameter=+:63=+:122=+:Last_Article_Display_Author=+:Boolean=+:FALSE=+:=+:0 ! parameter=+:63=+:124=+:Last_Article_Display_Cat=+:Boolean=+:TRUE=+:=+:0 ! parameter=+:63=+:123=+:Last_Article_Display_Date=+:Boolean=+:TRUE=+:=+:0 ! parameter=+:63=+:125=+:Last_Article_Display_Icon_View=+:Boolean=+:TRUE=+:=+:0 ! parameter=+:63=+:126=+:Last_Article_Display_Last_Author=+:Boolean=+:TRUE=+:=+:0 ! parameter=+:63=+:132=+:Last_Article_Mode=+:Menu_single_select=+:KB=+:a:2:{i:0;s:2:"KB";i:1;s:9:"KB_Reader";}=+:0 ! parameter=+:63=+:128=+:Last_Article_Number_Title=+:Number=+:15=+:=+:0 ! parameter=+:63=+:129=+:Last_Article_Target=+:Values=+:_blank=+:=+:0 ! parameter=+:63=+:130=+:Last_Article_Title_Length=+:Number=+:30=+:=+:0 parameter=+:0=+:0=+:0=+:endoflist=+:0=+:0 ! block=+:=+:Demo - Last Articles=+:Demo block=+:63=+:0=+:5=+:0=+:0=+:0=+:0=+:1=+:1 ! function=+:0=+:0=+:0=+:endoflist=+:0=+:0 |
|
From: Jon O. <jon...@us...> - 2006-06-29 13:13:51
|
Update of /cvsroot/mxbb/core/modules/mx_textblocks/admin In directory sc8-pr-cvs7.sourceforge.net:/tmp/cvs-serv24423/modules/mx_textblocks/admin Modified Files: mx_module_defs.php Log Message: Removed unneeded nav_menu parameter Selvens nav_menu fix for get_nav() Selvens fix for finding bbcode faq info when posting Index: mx_module_defs.php =================================================================== RCS file: /cvsroot/mxbb/core/modules/mx_textblocks/admin/mx_module_defs.php,v retrieving revision 1.19 retrieving revision 1.20 diff -C2 -d -r1.19 -r1.20 *** mx_module_defs.php 26 Jun 2006 21:32:23 -0000 1.19 --- mx_module_defs.php 29 Jun 2006 13:13:44 -0000 1.20 *************** *** 244,248 **** 'HTML_STATUS' => $html_status, ! 'BBCODE_STATUS' => $bbcode_status, 'SMILIES_STATUS' => $smilies_status, --- 244,248 ---- 'HTML_STATUS' => $html_status, ! 'BBCODE_STATUS' => sprintf($bbcode_status, '<a href="' . PHPBB_URL . append_sid("faq.$phpEx?mode=bbcode") . '" target="_phpbbcode">', '</a>'), 'SMILIES_STATUS' => $smilies_status, *************** *** 380,384 **** 'HTML_STATUS' => $html_status, ! 'BBCODE_STATUS' => $bbcode_status, 'SMILIES_STATUS' => $smilies_status, --- 380,384 ---- 'HTML_STATUS' => $html_status, ! 'BBCODE_STATUS' => sprintf($bbcode_status, '<a href="' . PHPBB_URL . append_sid("faq.$phpEx?mode=bbcode") . '" target="_phpbbcode">', '</a>'), 'SMILIES_STATUS' => $smilies_status, *************** *** 483,487 **** $template->assign_vars(array( 'HTML_STATUS' => $html_status, ! 'BBCODE_STATUS' => $bbcode_status, 'SMILIES_STATUS' => $smilies_status, 'L_PREVIEW' => $lang['Preview'], --- 483,487 ---- $template->assign_vars(array( 'HTML_STATUS' => $html_status, ! 'BBCODE_STATUS' => sprintf($bbcode_status, '<a href="' . PHPBB_URL . append_sid("faq.$phpEx?mode=bbcode") . '" target="_phpbbcode">', '</a>'), 'SMILIES_STATUS' => $smilies_status, 'L_PREVIEW' => $lang['Preview'], |
|
From: Jon O. <jon...@us...> - 2006-06-29 13:13:48
|
Update of /cvsroot/mxbb/core/modules/mx_navmenu In directory sc8-pr-cvs7.sourceforge.net:/tmp/cvs-serv24423/modules/mx_navmenu Modified Files: NavigationMenu.pak mx_menu_nav.php Log Message: Removed unneeded nav_menu parameter Selvens nav_menu fix for get_nav() Selvens fix for finding bbcode faq info when posting Index: mx_menu_nav.php =================================================================== RCS file: /cvsroot/mxbb/core/modules/mx_navmenu/mx_menu_nav.php,v retrieving revision 1.11 retrieving revision 1.12 diff -C2 -d -r1.11 -r1.12 *** mx_menu_nav.php 17 Jun 2006 20:45:22 -0000 1.11 --- mx_menu_nav.php 29 Jun 2006 13:13:44 -0000 1.12 *************** *** 39,43 **** // Define some parameters // - $menu_mode = $mx_menu_config['menu_mode']; $menu_display_style = $mx_menu_config['menu_display_style']; $menu_display_mode = $mx_menu_config['menu_display_mode']; --- 39,42 ---- *************** *** 46,51 **** // // Prevent this block to be used both in overall_header and as a block // ! if ( (defined('MX_OVERALL_NAVIGATION') && $menu_mode == 'block') || (!defined('MX_OVERALL_NAVIGATION') && $menu_mode == 'overall_header')) { $mx_block->show_title = false; --- 45,53 ---- // // Prevent this block to be used both in overall_header and as a block + // Define this menu block has been used on this page - either as a block or in the header. To avoid it being used several times // ! $nav_def_key = 'MX_NAV_MENU_' . $block_id; ! ! if ( defined($nav_def_key) ) { $mx_block->show_title = false; *************** *** 53,56 **** --- 55,59 ---- return; } + define($nav_def_key, true); // *************** *** 120,124 **** --- 123,132 ---- continue; } + $menuIsCat = true; + if ($catData[0]['cat_url'] == 0 && $menuData['page_id'] != 0) + { + $catData[0]['cat_url'] = $menuData['page_id']; + } } *************** *** 138,143 **** $cat_desc = mx_decode($cat_desc, $bbcode_uid, false); $cat_target = ( $catData[0]['cat_target'] == 0 ) ? '' : '_blank'; - $cat_url_tmp = mx_append_sid(PORTAL_URL . 'index.php?page=' . $catData[0]['cat_url'] . '&cat_link=' . intval($cat_id)); $catt = ( $catData[0]['cat_url'] != 0 ) ? '<a class="nav" href="' . $cat_url_tmp . '" target="' . $cat_target . '" /><span class="nav">' . $cat . '</span></a>' : '<span class="nav">' . $cat . '</span>'; --- 146,153 ---- $cat_desc = mx_decode($cat_desc, $bbcode_uid, false); + // + // Is this category a custom link? If not, link to first menu page. + // $cat_target = ( $catData[0]['cat_target'] == 0 ) ? '' : '_blank'; $cat_url_tmp = mx_append_sid(PORTAL_URL . 'index.php?page=' . $catData[0]['cat_url'] . '&cat_link=' . intval($cat_id)); $catt = ( $catData[0]['cat_url'] != 0 ) ? '<a class="nav" href="' . $cat_url_tmp . '" target="' . $cat_target . '" /><span class="nav">' . $cat . '</span></a>' : '<span class="nav">' . $cat . '</span>'; *************** *** 149,153 **** $current_cat = ($pageMapping[$mx_page->page_id] == $cat_id || intval($HTTP_GET_VARS['cat_link']) == $cat_id) ? true : false; ! // // Update cookie - if this was a cat link // --- 159,163 ---- $current_cat = ($pageMapping[$mx_page->page_id] == $cat_id || intval($HTTP_GET_VARS['cat_link']) == $cat_id) ? true : false; ! // // Update cookie - if this was a cat link // *************** *** 158,162 **** --- 168,174 ---- } + // // Generate the fold/unfold categories switches + // $cat_on = $current_cat ? true : ( isset($HTTP_COOKIE_VARS['mxNavCat_' . $block_id . $cat_id]) ? $HTTP_COOKIE_VARS['mxNavCat_' . $block_id . $cat_id] == 1 : $catData[0]['cat_show'] == 1 ); *************** *** 188,191 **** --- 200,204 ---- // $is_auth_ary = menu_auth(AUTH_VIEW, $menuData['menu_id'], $userdata, $menuData, $menuData['auth_view_group']); + if ( !$is_auth_ary['auth_view'] ) { *************** *** 300,304 **** --- 313,319 ---- 'CAT_WIDTH' => $cat_width, + // // mygosmenu + // 'MX_ROOT_PATH' => $mx_root_path, 'T_TR_COLOR1' => '#'.$theme['tr_color1'], Index: NavigationMenu.pak =================================================================== RCS file: /cvsroot/mxbb/core/modules/mx_navmenu/NavigationMenu.pak,v retrieving revision 1.6 retrieving revision 1.7 diff -C2 -d -r1.6 -r1.7 *** NavigationMenu.pak 7 Apr 2006 11:45:04 -0000 1.6 --- NavigationMenu.pak 29 Jun 2006 13:13:44 -0000 1.7 *************** *** 4,8 **** parameter=+:51=+:63=+:menu_display_mode=+:Radio_single_select=+:Vertical=+:a:2:{i:0;s:8:"vertical";i:1;s:10:"horizontal";}=+:0 parameter=+:51=+:93=+:menu_display_style=+:Radio_single_select=+:Standard=+:a:5:{i:0;s:8:"Standard";i:1;s:6:"Simple";i:2;s:8:"Advanced";i:3;s:12:"Advanced_app";i:4;s:18:"Overall_navigation";}=+:0 - parameter=+:51=+:94=+:menu_mode=+:Menu_single_select=+:block=+:a:2:{i:0;s:5:"block";i:1;s:14:"overall_header";}=+:0 parameter=+:51=+:64=+:menu_page_sync=+:Boolean=+:0=+:=+:0 parameter=+:51=+:66=+:Nav menu=+:nav_menu=+:=+:=+:0 --- 4,7 ---- |
|
From: Jon O. <jon...@us...> - 2006-06-29 13:13:48
|
Update of /cvsroot/mxbb/core/modules/mx_navmenu/admin In directory sc8-pr-cvs7.sourceforge.net:/tmp/cvs-serv24423/modules/mx_navmenu/admin Modified Files: mx_module_defs.php Log Message: Removed unneeded nav_menu parameter Selvens nav_menu fix for get_nav() Selvens fix for finding bbcode faq info when posting Index: mx_module_defs.php =================================================================== RCS file: /cvsroot/mxbb/core/modules/mx_navmenu/admin/mx_module_defs.php,v retrieving revision 1.21 retrieving revision 1.22 diff -C2 -d -r1.21 -r1.22 *** mx_module_defs.php 27 Jun 2006 18:12:22 -0000 1.21 --- mx_module_defs.php 29 Jun 2006 13:13:44 -0000 1.22 *************** *** 309,313 **** else { ! $mx_nav_data = get_nav_menu($block_id); $mx_cache->put( '_menu_' . $block_id, $mx_nav_data ); } --- 309,313 ---- else { ! $mx_nav_data = mx_get_nav_menu($block_id); $mx_cache->put( '_menu_' . $block_id, $mx_nav_data ); } |