<% @ LANGUAGE="VBScript" %> Super Bowl Feeders Manufacturing Company <% Set DBConn = Server.CreateObject("ADODB.Connection") Set rsSections = Server.CreateObject("ADODB.Recordset") Set rsEntries = Server.CreateObject("ADODB.Recordset") DBConn.Open "SuperBowlFeeders" rsSections.Open "SELECT * FROM AccessorySections WHERE AccessorySection <> 'NONE'", DBConn %>
<% Dim position Dim strCaption Dim image1 Dim image2 While Not rsSections.EOF rsEntries.Open "SELECT * FROM Products WHERE AccessorySection = '" & rsSections("AccessorySection") & "' ORDER BY Product", DBConn Response.Write("

") If rsSections("AccessorySection") = "HATS" Then strCaption = "Collectible Caps" ElseIf rsSections("AccessorySection") = "SHIRTS" Then strCaption = "Collectible T-Shirts" End If Response.Write("" & strCaption & "") ' commented out the following two lines when t-shirts were added, because I didn't ' have any caption image for the t-shirts ' Response.Write("") Response.Write("

") While Not rsEntries.EOF position = InStr(rsEntries("ImageName"), ";") image1 = Left(rsEntries("ImageName"), position-1) image2 = Mid(rsEntries("ImageName"), position+1) Response.Write("") Response.Write("
") Response.Write("") Response.Write("") Response.Write("") Response.Write("") Response.Write("") Response.Write("") Response.Write("") Response.Write("") Response.Write("") Response.Write("") Response.Write("") Response.Write("") Response.Write("") Response.Write("") Response.Write("
") Response.Write("") Response.Write("") Response.Write("" & rsEntries("Description") & "") Response.Write("
") Response.Write("" & rsEntries("AccessoryDescription") & "") Response.Write("
") Response.Write("Order Now!") Response.Write("
") Response.Write("") Response.Write("
") Response.Write("



") rsEntries.MoveNext Wend rsEntries.Close rsSections.MoveNext Wend %>
<% DBConn.Close %>