PMA\libraries\DisplayResults::_getHtmlPageSelector PHP 메소드

_getHtmlPageSelector() 개인적인 메소드

Possibly return a page selector for table navigation
private _getHtmlPageSelector ( string $table_navigation_html ) : array
$table_navigation_html string the current navigation HTML
리턴 array ($table_navigation_html, $nbTotalPage)
    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);
    }
DisplayResults