diff --git a/admin/callhistory.php b/admin/callhistory.php index 49fce497..eb6cb737 100644 --- a/admin/callhistory.php +++ b/admin/callhistory.php @@ -100,7 +100,7 @@ if ($operator_id) if (!isset($_GET['csv'])) $sql .= " LIMIT 500"; - else $sql .= " LIMIT 5000"; +// else $sql .= " LIMIT 5000"; no limit when using CSV $rs = $db->Execute($sql); if (empty($rs)) @@ -110,8 +110,10 @@ if ($operator_id) else { if (isset($_GET['csv'])) - { - $qds = str_replace(' ','_',$_GET['dq']); $smpds = str_replace(' ','_',$_GET['ds']); + { + $qds = $smpds = ""; + if (isset($_GET['dq'])) $qds = str_replace(' ','_',$_GET['dq']); + if (isset($_GET['ds'])) $smpds = str_replace(' ','_',$_GET['ds']); $fn = "callhistory-" . $qds . $smpds . date("_d-M-Y_H-i") . ".csv"; header("Content-Type: text/csv"); @@ -160,7 +162,17 @@ if ($operator_id) print "