"; $result = mysql_query("Select photoID from gns_yearbook where photoID < $id and category = '$category' order by photoID DESC limit 1"); if($row = mysql_fetch_assoc($result)) { if($row['photoID'] != $id) { echo "Prev | "; } } echo "Index"; $result = mysql_query("Select photoID from gns_yearbook where photoID > $id and category = '$category' order by photoID limit 1"); if($row = mysql_fetch_assoc($result)) { if($row['photoID'] != $id) { echo " | Next"; } } echo "

"; echo "$title

$title
$description

"; $result = mysql_query("Select photoID from gns_yearbook where photoID < $id and category = '$category' order by photoID DESC limit 1"); if($row = mysql_fetch_assoc($result)) { if($row['photoID'] != $id) { echo "Prev | "; } } echo "Index"; $result = mysql_query("Select photoID from gns_yearbook where photoID > $id and category = '$category' order by photoID limit 1"); if($row = mysql_fetch_assoc($result)) { if($row['photoID'] != $id) { echo " | Next"; } } echo "


"; if($id && $admin) { echo "
Delete Photo
"; } include '../inc/footer.php'; ?>