I have this for navigation, and when I switch to page 2, it will lose the &type= Let's say I select "checked", the first page it shows fine, as it het the whole string, but when I switch pages it loses... here's the code:
// navigation
if($_GET['start'] && is_numeric($_GET['start']))
{
$start=$_GET['start'];
$start=((int)($start/$search_count))*$search_count;
}
else $start=0;
$info['curpage']=ceil(($start+1)/$search_count);
$info['total_pages']=ceil($info['total_results_count']/$search_count);
$navigation=array();
$navigation[]='<span class="navi navi_current"> -'.$info['curpage'].'- </span>'."\n";
$inc=$dec=$start;
$tcnt=0;
for($i=0;$i<9;$i++)
{
$inc+=$search_count;
$incp=ceil(($inc+1)/$search_count);
$dec-=$search_count;
$decp=ceil(($dec+1)/$search_count);
if($inc<$info['total_results_count'])
{
array_push($navigation,'<span class="navi"> <a href="./?q='.$_GET['q'].'&start='.$inc.'"&type='.$_GET['type'].'>'.$incp.'</a> </span> '."\n");
$tcnt++;
}
if($dec>=0)
{
array_unshift($navigation,'<span class="navi"> <a href="./?q='.$_GET['q'].'&start='.$dec.'">'.$decp.'</a> </span> '."\n");
$tcnt++;
}
if($tcnt>=10) break;
}
$navigation=join("",$navigation);
// end navigation
I've tried adding &type='.$_GET['type']. to the array_unshift, but it doesn't work.. any help will be appreciated! thanks.