I believe the problem is with the segments below. Any catagory or search that returns more than 999 entries from the mysql database causes it to go to 1 page only for results ie. normally 5o entries would display as 50 on 2 pages it does this fine on hundreds of entries but at say 2000 entires it says 2000 on 1 page and the list of page numbers doesn't come up. I think something is limiting it to 3digits in the count . Not sure any help would be appreciated. Code follows.
//------------------------
// Page numbers..
//------------------------
function pageNumbers($count,$limit,$url,$page,$catname,$search=false)
{
global $ds_cats3,$ds_cats4,$ds_search4,$ds_search5,$SETTINGS;
$numofpages = $count/$limit;
$data = '';
$find = array('{count}',
'{cat}',
'{pages}'
);
$replace = array($count,
$catname,
ceil($numofpages)
);
for ($i=1; $i<=$numofpages; ++$i)
{
if ($i==$page)
{
$data .= '<span class="current_page">'.$i.'</span> ';
}
else
{
$data .= '<a href="'.($SETTINGS->modr && !$search ? $url.PAGE_URL_TEXT.'-'.$i.'.html' : 'index.php?'.$url.'&page='.$i).'" title="'.$i.'">'.$i.'</a> ';
}
}
if ($count % $limit!=0)
{
if ($i==$page)
{
$data .= '<span class="current_page">'.$i.'</span> ';
}
else
{
$data .= '<a href="'.($SETTINGS->modr && !$search ? $url.PAGE_URL_TEXT.'-'.$i.'.html' : 'index.php?'.$url.'&page='.$i).'" title="'.$i.'">'.$i.'</a> ';
}
}
// For categories..
$pageData = '<br>
<div id="page_numbers">
'.(ceil($numofpages)>0 ? str_replace($find,$replace,ceil($numofpages)==1 ? $ds_cats4 : $ds_cats3) : '').'<br><br>
'.$data.'
</div>
';
// For search..
$searchData = '<br>
<div id="page_numbers">
'.(ceil($numofpages)>0 ? str_replace($find,$replace,ceil($numofpages)==1 ? $ds_search5 : $ds_search4) : '').'<br><br>
'.$data.'
</div>
';
return ($search ? $searchData : $pageData);
}