|
<% getleftcol(pg4) %> |
|
| <% getrightcol(pg4) %><% getHeading "", hdfitems, "" %> |
|
|
|
<%
'Open database get featured items.
set rs=openrs("SELECT id, name, price, saleprice, hideprice, onsale, smallimage, shortdesc, itemno FROM items WHERE active='Yes' AND feature='Yes' ORDER BY " & sortby)
if not rs.eof then
rs.movefirst
rs.pagesize = numperpage
totalpages = rs.pagecount
rs.absolutepage = currentpage
end if
count=1
if not rs.eof then
%>
| |
<%=tfeatures1%> |
|
<%=tfeatures2%> |
<%=tfeatures3%> |
<%
do while not rs.eof and count <= rs.pagesize
itemname=rs("name")
price=rs("price")
saleprice=rs("saleprice")
hideprice=rs("hideprice")
if hideprice="ON" then
hideprice=1
else
hideprice=0
end if
onsale=rs("onsale")
tempimage=rs("smallimage")
'description=rs("description")
shortdesc=rs("shortdesc")
itemno=rs("itemno")
'What to do if no image.
imagefound=""
if Len(tempimage)>0 then
smallimage=tempimage
else
imagefound="no"
end if
%>
<% '--- determine whether to display image ---
if imagefound="no" then
else
%> ">
<%=listimgheight%> hspace="5" src="../images/<%=smallimage%>" alt="<%=itemname%>">
<%end if%> |
"><%=itemname%>
<%=shortdesc%>
"><%=tfeatures4%> |
|
<%=itemno%> |
<%
if hideprice=0 then
'Display price or sale price? ---
if onsale="Yes" or onsale="yes" then
%> <% =showCurr(price)%>
<% =showCurr(saleprice)%> <%
else
response.write(showCurr(price))
end if
end if%> |
|
<%
rs.movenext
count = count + 1
loop
%>
|
| <%=tendofpage1 & currentpage & tendofpage2 & totalpages & tendofpage3%> |
<%
'Create Previous Page link.
if not currentpage = 1 Then
%>
| <% showbutton tprevbutt & maxrec,"javascript:(document.prev.submit())","" %>
|
<%
end if
'Create Next Page link.
if not currentpage = totalpages then
%>
<% showbutton tnextbutt,"","next" %>
|
<%
end if
%>
|
| <%=tfeatures5%> |
<%
end if
rs.close
set rs=nothing
%>
|
|
|
|