Make pagesize 'all' work again. Bug found by apellido jr., wilfredo p.
authorkkalev <kkalev>
Thu, 2 Sep 2004 12:02:54 +0000 (12:02 +0000)
committerkkalev <kkalev>
Thu, 2 Sep 2004 12:02:54 +0000 (12:02 +0000)
dialup_admin/Changelog
dialup_admin/htdocs/badusers.php3
dialup_admin/htdocs/failed_logins.php3
dialup_admin/htdocs/user_accounting.php3
dialup_admin/htdocs/user_stats.php3

index 445af18..38e56c4 100644 (file)
@@ -21,6 +21,7 @@ Ver 1.75:
   Add two more lines in the output stating the number of current open sessions and the time used.
 * Move a few header() calls after including config.php3 so that we have access to the relevant
   variables.
+* Make pagesize 'all' work again. Bug found by apellido jr., wilfredo p.
 Ver 1.72:
 * Move the xlat function to a separate file in lib/xlat.php3
 * Add a lib/sql/nas_list.php3 to also get the nas list from sql (naslist.conf still works)
index 6df4d30..ada7422 100644 (file)
@@ -31,7 +31,7 @@ $prev_str = da_sql_escape_string($prev_str);
 
 $num = 0;
 $pagesize = ($pagesize) ? $pagesize : 10;
-if (!is_numeric($pagesize))
+if (!is_numeric($pagesize) && $pagesize != 'all')
        $pagesize = 10;
 $limit = ($pagesize == 'all') ? '' : "LIMIT $pagesize";
 $selected[$pagesize] = 'selected';
index d2ee47e..9aa6c1b 100644 (file)
@@ -37,7 +37,7 @@ $now_str = da_sql_escape_string($now_str);
 $prev_str = da_sql_escape_string($prev_str);
 
 $pagesize = ($pagesize) ? $pagesize : 10;
-if (!is_numeric($pagesize))
+if (!is_numeric($pagesize) && $pagesize != 'all')
        $pagesize = 10;
 $limit = ($pagesize == 'all') ? '' : "LIMIT $pagesize";
 $selected[$pagesize] = 'selected';
index 1b59ce6..7742784 100644 (file)
@@ -29,7 +29,7 @@ $now_str = ($now_str != '') ? "$now_str" : date($config[sql_date_format],$now +
 $prev_str = ($prev_str != '') ? "$prev_str" : date($config[sql_date_format], $now - 604800 );
 $num = 0;
 $pagesize = ($pagesize) ? $pagesize : 10;
-if (!is_numeric($pagesize))
+if (!is_numeric($pagesize) && $pagesize != 'all')
        $pagesize = 10;
 $limit = ($pagesize == 'all') ? '' : "LIMIT $pagesize";
 $selected[$pagesize] = 'selected';
index 13b5ab1..17b516e 100644 (file)
@@ -33,7 +33,7 @@ if ($start == '' && $stop == ''){
 $start = da_sql_escape_string($start);
 $stop = da_sql_escape_string($stop);
 $pagesize = ($pagesize) ? $pagesize : 10;
-if (!is_numeric($pagesize))
+if (!is_numeric($pagesize) && $pagesize != 'all')
        $pagezise = 10;
 if ($pagesize > 100)
        $pagesize = 100;