Skip to content
Snippets Groups Projects
Commit 8781a19e authored by arnaud's avatar arnaud
Browse files

FIX pagination on resources

parent 66f62243
No related branches found
No related tags found
No related merge requests found
......@@ -91,15 +91,11 @@ if (empty($sortorder)) $sortorder="ASC";
if (empty($sortfield)) $sortfield="t.rowid";
if (empty($arch)) $arch = 0;
$page = GETPOST('page','int');
if ($page == -1) {
$page = 0 ;
}
$limit = GETPOST("limit")?GETPOST("limit","int"):$conf->liste_limit;
$page = GETPOST("page");
$page = is_numeric($page) ? $page : 0;
$page = $page == -1 ? 0 : $page;
if (! $sortfield) $sortfield="p.ref";
if (! $sortorder) $sortorder="ASC";
$offset = $conf->liste_limit * $page ;
$offset = $limit * $page ;
$pageprev = $page - 1;
$pagenext = $page + 1;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment