not really like that... here is my whole page... i'm looking for some help to add the 1234.. between the [Prev] and [Next] links. I have highlighted in bold where i need the help...
<?php
if($dbconnected==0){require('connect_db.php');}
$queryname=$GET['Section'];
$Section=addslashes(urldecode($queryname));
$offset=$GET['offset'];
$sql="SELECT * FROM Products WHERE Category='$Section' ORDER BY ProdID LIMIT $offset,5";
$result=mysql_query($sql,$db);
if($row=mysql_fetch_array($result))
{
$Category=stripslashes(stripslashes($Section));
print "<br/><div class=\"category\">$Category</div>";
print "<div align=\"right\">";
////// Previous Link //////
$qn=urlencode($Category);
$prevoffset1=$offset - 5;
if($offset>1){print "<a href=\"?phpid=view_products&Section=$qn&offset=$prevoffset1\"><< Previous</a>";}
print " ";
////// Next Link ////////
$sqlnum1=mysql_query("SELECT * FROM Products WHERE Category='$Section'");
$totalnum1=mysql_num_rows($sqlnum1);
$totalnum1=$totalnum1 - 5;
$nextoffset1=$offset + 5;
if($offset<$totalnum1){print "<a href=\"?phpid=view_products&Section=$qn&offset=$nextoffset1\">Next >></a>";}
print "</div>";
do{
$Name=stripslashes($row['Name']);
$Picture=$row['Picture'];
$ProdID=$row['ProdID'];
print "
<br/><br/>
<table width=\"450\" border=\"2\" bordercolor=\"#006699\" cellpadding=\"5\" cellspacing=\"1\">
<tr>
<td width=\"100\">
<img src=\"pics/$Picture\" width=\"100\">
</td>
<td width=\"265\">
<div class=\"prodname\">$Name</div>
</td>
<td width=\"85\">
<a href=\"?phpid=view_products2&prodid=$ProdID&Section=$qn&offset=$offset\"><center><img src=\"images/more_info.gif\" width=\"80\" height=\"21\" border=\"0\"></a></center>
</td>
</tr>
</table>
<br/>
";
}
while($row=mysql_fetch_array($result));
print "<div align=\"right\">";
////// Previous Link //////
$qn=urlencode($Category);
$prevoffset2=$offset - 5;
if($offset>1){print "<a href=\"?phpid=view_products&Section=$qn&offset=$prevoffset2\"><< Previous</a>";}
print " ";
////// Page Links //////
$sqlnum2=mysql_query("SELECT * FROM Products WHERE Category='$Section'");
$totalnum2=mysql_num_rows($sqlnum2);
$pages=ceil($totalnum2/5);
[COLOR=red]WHERE DO I GO FROM HERE???[/COLOR][/B]
////// Next Link ////////
$totalnum2=$totalnum2 - 5;
$nextoffset2=$offset + 5;
if($offset<$totalnum2){print "<a href=\"?phpid=view_products&Section=$qn&offset=$nextoffset2\">Next >></a>";}
print "</div>";
}
else{print "<div class=\"main\" align=\"center\"><br/><br/><br/>No Products Found.</div>";}
?>