X-Git-Url: https://delta.frontaccounting.com/gitweb/?a=blobdiff_plain;f=includes%2Fdb_pager.inc;h=819b4757f5c7e3381b749f9bc3d7073b8ea187ec;hb=2e181b13aa722a43e78b897404912d6b13a0a937;hp=ef74a95de80135fc1e6de45a37d4dfcfa40b24e7;hpb=8430384235d77fb7f8d8ca894e5efedd04d6bc0b;p=fa-stable.git diff --git a/includes/db_pager.inc b/includes/db_pager.inc index ef74a95d..819b4757 100644 --- a/includes/db_pager.inc +++ b/includes/db_pager.inc @@ -1,13 +1,13 @@ . + See the License here . ***********************************************************************/ // // Controler part of database table pager with column sort. @@ -303,7 +303,8 @@ class db_pager { return false; $row = db_fetch_row($result); $this->rec_count = $row[0]; - $this->max_page = ceil($this->rec_count/$this->page_len); + $this->max_page = $this->page_len ? + ceil($this->rec_count/$this->page_len) : 0; if ($go_debug) { // FIX - need column name parsing, but for now: // check if field names are set explicite in col def