Here I am getting this error somewhere in this block of code.
Parse error: parse error, unexpected T_LNUMBER, expecting T_VARIABLE or '$' in .......
if ($whichpage == $1)
{
echo "<b><a href=\"". $_SERVER['PHP_SELF']? .".SID."&whichpage=$i\">
Page $i</a></b>";
}