|
From: MW <jo...@us...> - 2008-02-09 12:50:27
|
Update of /cvsroot/mxbb/core/modules/mx_rebuild_search_tables/admin In directory sc8-pr-cvs16.sourceforge.net:/tmp/cvs-serv29246/modules/mx_rebuild_search_tables/admin Modified Files: admin_rebuild_search.php admin_rebuild_mx_search.php Log Message: part of project wide change of using request_vars wrapper class instead of explicite and unfiltered $HTML_*_VARS Index: admin_rebuild_mx_search.php =================================================================== RCS file: /cvsroot/mxbb/core/modules/mx_rebuild_search_tables/admin/admin_rebuild_mx_search.php,v retrieving revision 1.9 retrieving revision 1.10 diff -C2 -d -r1.9 -r1.10 *** admin_rebuild_mx_search.php 4 Feb 2008 16:54:25 -0000 1.9 --- admin_rebuild_mx_search.php 9 Feb 2008 12:50:23 -0000 1.10 *************** *** 11,15 **** $start_time = time (); ! $time_limit = $HTTP_GET_VARS['time_limit']; define ('IN_PORTAL', 1); --- 11,15 ---- $start_time = time (); ! $time_limit = $mx_request_vars->get('time_limit', MX_TYPE_NO_TAGS); define ('IN_PORTAL', 1); *************** *** 43,47 **** $page_title = $lang['Page_title']; ! if (isset ($HTTP_GET_VARS['start'])) { function onTime () --- 43,47 ---- $page_title = $lang['Page_title']; ! if ($mx_request_vars->is_get('start')) { function onTime () *************** *** 65,69 **** } ! $start = $HTTP_GET_VARS['start']; if ($start == 0) --- 65,69 ---- } ! $start = $mx_request_vars->get('start', MX_TYPE_INT); if ($start == 0) *************** *** 104,108 **** } ! $total_num_rows = (isset ($HTTP_GET_VARS['total_num_rows'])) ? $HTTP_GET_VARS['total_num_rows'] : $total_num_rows; // --- 104,108 ---- } ! $total_num_rows = $mx_request_vars->get('total_num_rows', MX_TYPE_INT, $total_num_rows); // *************** *** 119,123 **** OR par.parameter_type = 'WysiwygTextBlock' ) AND sys.sub_id = 0 ! LIMIT ".$start.", ". $HTTP_GET_VARS['post_limit']; /* --- 119,123 ---- OR par.parameter_type = 'WysiwygTextBlock' ) AND sys.sub_id = 0 ! LIMIT ".$start.", ". $mx_request_vars->get('post_limit', MX_TYPE_INT); /* *************** *** 144,151 **** if (($start + $num_rows) != $total_num_rows) { ! $form_action = append_sid ("admin_rebuild_mx_search.$phpEx?start=". ($start + $num_rows) ."&total_num_rows=$total_num_rows&post_limit=". $HTTP_GET_VARS['post_limit'] ."&time_limit=$time_limit&refresh_rate=". $HTTP_GET_VARS['refresh_rate']); $next = $lang['Next']; $template->assign_vars(array( ! "META" => '<meta http-equiv="refresh" content="'. $HTTP_GET_VARS['refresh_rate'] .';url='. $form_action .'">') ); } --- 144,151 ---- if (($start + $num_rows) != $total_num_rows) { ! $form_action = append_sid ("admin_rebuild_mx_search.$phpEx?start=". ($start + $num_rows) ."&total_num_rows=$total_num_rows&post_limit=". $mx_request_vars->get('post_limit', MX_TYPE_INT) ."&time_limit=$time_limit&refresh_rate=". $mx_request_vars->get('refresh_rate', MX_TYPE_INT)); $next = $lang['Next']; $template->assign_vars(array( ! "META" => '<meta http-equiv="refresh" content="'. $mx_request_vars->get('refresh_rate', MX_TYPE_INT) .';url='. $form_action .'">') ); } Index: admin_rebuild_search.php =================================================================== RCS file: /cvsroot/mxbb/core/modules/mx_rebuild_search_tables/admin/admin_rebuild_search.php,v retrieving revision 1.9 retrieving revision 1.10 diff -C2 -d -r1.9 -r1.10 *** admin_rebuild_search.php 4 Feb 2008 16:54:25 -0000 1.9 --- admin_rebuild_search.php 9 Feb 2008 12:50:23 -0000 1.10 *************** *** 11,15 **** $start_time = time (); ! $time_limit = $HTTP_GET_VARS['time_limit']; define ('IN_PORTAL', 1); --- 11,15 ---- $start_time = time (); ! $time_limit = $mx_request_vars->get('time_limit', MX_TYPE_INT); define ('IN_PORTAL', 1); *************** *** 43,47 **** $page_title = $lang['Page_title']; ! if (isset ($HTTP_GET_VARS['start'])) { function onTime () --- 43,47 ---- $page_title = $lang['Page_title']; ! if ($mx_request_vars->is_get('start')) { function onTime () *************** *** 65,69 **** } ! $start = $HTTP_GET_VARS['start']; if ($start == 0) --- 65,69 ---- } ! $start = $mx_request_vars->get('start', MX_TYPE_INT); if ($start == 0) *************** *** 88,94 **** } ! $total_num_rows = (isset ($HTTP_GET_VARS['total_num_rows'])) ? $HTTP_GET_VARS['total_num_rows'] : $total_num_rows; ! $sql = "SELECT post_id, post_subject, post_text FROM ". POSTS_TEXT_TABLE ." LIMIT $start, ". $HTTP_GET_VARS['post_limit']; if ( !$result = $db->sql_query ($sql) ) --- 88,94 ---- } ! $total_num_rows = $mx_request_vars->get('total_num_rows', MX_TYPE_INT, $total_num_rows); ! $sql = "SELECT post_id, post_subject, post_text FROM ". POSTS_TEXT_TABLE ." LIMIT $start, ". $mx_request_vars->get('post_limit', MX_TYPE_INT); if ( !$result = $db->sql_query ($sql) ) *************** *** 111,118 **** if (($start + $num_rows) != $total_num_rows) { ! $form_action = append_sid ("admin_rebuild_search.$phpEx?start=". ($start + $num_rows) ."&total_num_rows=$total_num_rows&post_limit=". $HTTP_GET_VARS['post_limit'] ."&time_limit=$time_limit&refresh_rate=". $HTTP_GET_VARS['refresh_rate']); $next = $lang['Next']; $template->assign_vars(array( ! "META" => '<meta http-equiv="refresh" content="'. $HTTP_GET_VARS['refresh_rate'] .';url='. $form_action .'">') ); } --- 111,118 ---- if (($start + $num_rows) != $total_num_rows) { ! $form_action = append_sid ("admin_rebuild_search.$phpEx?start=". ($start + $num_rows) ."&total_num_rows=$total_num_rows&post_limit=". $mx_request_vars->get('post_limit',MX_TYPE_INT) ."&time_limit=$time_limit&refresh_rate=". $mx_request_vars->get('refresh_rate', MX_TYPE_INT)); $next = $lang['Next']; $template->assign_vars(array( ! "META" => '<meta http-equiv="refresh" content="'. $mx_request_vars->get('refresh_rate', MX_TYPE_INT) .';url='. $form_action .'">') ); } |