<%
'if session("rights")<>"true" then
'Response.Redirect "administrator.htm"
'end if
dim p
dim pp
dim inttotalpages
dim fldf
dim intrec
dim strquote
dim strscriptname
strquote=chr(34)
set rs=server.CreateObject("adodb.recordset")
rs.PageSize=16
rs.CursorLocation=aduseclient
rs.Open "select code,description,filename from products where displaygeneral='on' order by description asc",con,adOpenKeyset
if not rs.EOF then
imagepath=server.MapPath(".") & "\images_dynamic\"
p=trim(Request.QueryString("page"))
if p ="" then
pp=1
else
if p < 1 then
pp=1
else
if cint(p) > cint(rs.PageCount) then
pp=rs.PageCount
else
pp=p
end if
end if
end if
rs.AbsolutePage=pp
Response.Write "
"
x=0
for intrec=1 to rs.PageSize
if not rs.EOf then
if x=0 then
Response.Write "
"
strscriptname=Request.ServerVariables("")
Response.Write " First Page"
if cint(pp)=1 then
Response.Write " Previous Page"
else
Response.Write " Previous Page "
end if
if cint(pp)=cint(rs.PageCount) then
Response.Write " Next Page"
else
Response.Write " Next Page "
end if
pp=rs.PageCount
Response.Write " Last Page "
Response.Write "