diff --git a/web/lib/pkgfuncs.inc b/web/lib/pkgfuncs.inc index 1e92a904..c559750e 100644 --- a/web/lib/pkgfuncs.inc +++ b/web/lib/pkgfuncs.inc @@ -608,18 +608,15 @@ function pkg_search_page($SID="") { # determine paging variables # + if (intval($_GET['O'])) { + $O = $_GET['O']; + } else { + $O = 0; + } $_REQUEST["PP"] ? $PP = intval($_REQUEST["PP"]) : $PP = 25; if ($PP < 25) {$PP = 25;} if ($PP > 100) {$PP = 100;} - $_REQUEST["O"] ? $O = intval($_REQUEST["O"]) : $O = 0; - if ($_REQUEST["do_More"]) { - $O += $PP; - } elseif ($_REQUEST["do_Less"]) { - $O -= $PP; - } - if ($O < 0) { - $O = 0; - } + if ($_REQUEST["do_Search"] && $_REQUEST["do_Search"] != 1) { # reset the offset to zero if they hit Go # @@ -1062,6 +1059,7 @@ function pkg_search_page($SID="") { # print "