<html>
<head>
<title>Untitled Document</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
</head>
<body bgcolor="#FFFFFF" text="#000000" >

<table width="50%" border="0" cellspacing="0" cellpadding="0" height="40" align="center">
<tr>

<% ID = request.querystring("ID")


Set objCon = Server.CreateObject ("ADODB.Connection")
Set objRec = Server.CreateObject ("ADODB.Recordset")
objCon.Open Dbcon
SQL = "SELECT * FROM gallery WHERE ID = " & ID
objRec.Open SQL, objCon
if ID > 12 then
Response.Write("fine")
else
dim follow
follow = ID +1
if ObjRec.Eof then
Response.Redirect "dispimage.asp?id=" & follow & ""
end if



Response.write "<td valign=top height=67 width=""100%"">"

If Request.querystring("res")="" Then
Response.write "<p align=Center>[img]& ObjRec([/img]</a> " &_
"<p align=center><a href=javascript:history.back(1)>Back</a>"

End if%>

</td>
</tr>
</table>




<p align="center">">avanti</p>
<%end if%>
</body>
</html>