diff --git a/htdocs/edit.php b/htdocs/edit.php index f52d549..87b5d69 100644 --- a/htdocs/edit.php +++ b/htdocs/edit.php @@ -67,6 +67,12 @@ section>form label textarea{ diff --git a/htdocs/index.php b/htdocs/index.php index 8e37d3d..d8ed206 100644 --- a/htdocs/index.php +++ b/htdocs/index.php @@ -6,10 +6,13 @@ use MessageBoard\Database\DbMessage; $db = new DbMessage(); -$page = !empty($_GET["p"])?$_GET["p"]:1; -$max_count = $db->getCount(); +$page = !empty($_GET["p"])?(int)$_GET["p"]:1; +$max_count = !empty($_GET['rowcount']) ? (int)$_GET['rowcount'] : $db->getCount(); $max_page = ceil($max_count/$list_max_count); $list = $db->getList($page, $list_max_count); + +// $db->query("SELECT SQL_CALC_FOUND_ROWS * FROM xxx WHERE name='abc' LIMIT 100,10"); +// $max_count = $db->getOne("SELECT FOUND_ROWS()"); ?> @@ -86,6 +89,21 @@ div.table-func {
+ 0) { + ?> + + + + + + + + + + + + 0) { echo '
idtitleupdated_ataction