";
if($_GET['sort'] == "") {$_GET['sort'] = "DU"; }
if(isset($page) and $page>1)
{
if($page > 20) {
for($i=$page-10; $i<$page; $i++) {
if($i>=$page-10) echo " ";
echo " ", build_href("query_clean.php", $query . "&hitlist=true&page=" . $i . "&sort=" . $_GET['sort'], $i); }}
if($page<=20) {
for($i=1; $i<$page; $i++) {
if($i>=1) echo " ";
echo " ", build_href("query_clean.php", $query . "&hitlist=true&page=" . $i . "&sort=" . $_GET['sort'], $i); }}}
if($sum>$pagesize)
{ if(isset($page)) echo " ";
else $page=1;
echo $page, " ";
if($page > 10) {
for($i=$page; $i<($sum / $pagesize); $i++){
if($i>=$page and $i-$page <= 10) {echo " ";
echo build_href("query_clean.php", $query . "&hitlist=true&page=" . ($i+1) . "&sort=" . $_GET['sort'], ($i+1));}}}
if($page <= 10) {
for($i=$page; $i<($sum / $pagesize); $i++){
if($i>=$page and $i-$page <= 19) {echo " ";
echo build_href("query_clean.php", $query . "&hitlist=true&page=" . ($i+1) . "&sort=" . $_GET['sort'], ($i+1));}}}
}
echo " |
";
?>