private function _getHtmlPageSelector($table_navigation_html) { $pageNow = @floor($_SESSION['tmpval']['pos'] / $_SESSION['tmpval']['max_rows']) + 1; $nbTotalPage = @ceil($this->__get('unlim_num_rows') / $_SESSION['tmpval']['max_rows']); if ($nbTotalPage > 1) { $table_navigation_html .= '<td>'; $_url_params = array('db' => $this->__get('db'), 'table' => $this->__get('table'), 'sql_query' => $this->__get('sql_query'), 'goto' => $this->__get('goto'), 'is_browse_distinct' => $this->__get('is_browse_distinct')); //<form> to keep the form alignment of button < and << // and also to know what to execute when the selector changes $table_navigation_html .= '<form action="sql.php' . URL::getCommon($_url_params) . '" method="post">'; $table_navigation_html .= Util::pageselector('pos', $_SESSION['tmpval']['max_rows'], $pageNow, $nbTotalPage, 200, 5, 5, 20, 10); $table_navigation_html .= '</form>' . '</td>'; } return array($table_navigation_html, $nbTotalPage); }