<% Brand = request.querystring("Brand") myStyle = request.querystring("myStyle") Category = request.querystring("Category") if Brand="" and myStyle="" and Category="" then Category="Dresses" end if dqstr = "" if Brand<>"" then dqstr = dqstr & "brand=" & Server.URLEncode(Brand) end if if myStyle<>"" then if dqstr <> "" then dqstr = dqstr & "&" end if dqstr = dqstr & "myStyle=" & myStyle end if if Category<>"" then if dqstr <> "" then dqstr = dqstr & "&" end if dqstr = dqstr & "Category=" & Server.URLEncode(Category) end if ParentCode = "" if request.querystring("parent") <> "" then ParentCode = request.querystring("parent") end if if request.querystring("prodcode") <> "" then prodcode = request.querystring("prodcode") else response.redirect "products.asp?" & dqstr end if OutofStock = false Set DBConn = Server.CreateObject("ADODB.Connection") DBConn.Open productsDB Set rs = Server.CreateObject("ADODB.RecordSet") Set rs2 = Server.CreateObject("ADODB.RecordSet") Set fso = CreateObject("Scripting.FileSystemObject") %> Electric Alice
<% %>
<% rs.open "SELECT * FROM Products where ProductCode='" & prodcode & "'",DBConn,1,3 if not rs.eof then %>

<%=rs("ProductName")%> << Back to Products

Click to view categories

Shop by brand:

    <% rs2.open "SELECT distinct Brand FROM Products",DBConn,1,3 do while not rs2.eof if rs2("Brand")<>"" then qstr = "?brand=" & Server.URLEncode(rs2("Brand")) end if %> <% if Brand = rs2("Brand") then %>
  • <%=rs2("Brand")%>
  • <% else %>
  • <%=rs2("Brand")%>
  • <% end if %> <% rs2.movenext loop rs2.close %>

Shop by style:

    <% For j = 1 to 5 select case j case 1: aStyle = "Fairy" case 2: aStyle = "Punk" case 3: aStyle = "Gothic" case 4: aStyle = "Lolita" case 5: aStyle = "Mori" end select qstr = "?myStyle=" & aStyle %> <% if myStyle = aStyle then %>
  • <%=aStyle%>
  • <% else %>
  • <%=aStyle%>
  • <% end if %> <% next %>

Shop by item type:

    <% rs2.open "SELECT distinct Category FROM Products",DBConn,1,3 do while not rs2.eof if rs2("Category")<>"" then qstr = "?Category=" & Server.URLEncode(rs2("Category")) end if %> <% if Category = rs2("Category") then %>
  • <%=rs2("Category")%>
  • <% else %>
  • <%=rs2("Category")%>
  • <% end if %> <% rs2.movenext loop rs2.close %>
" method="post">
_1.jpg" id="largeimage">_1.jpg" id="bigpic" />

<%=rs("Description")%>

<%=rs("LongDescription")%>

Measurements

<%=rs("MeasureMents")%>

Price

<%if rs("SpecialPrice")>0 then%><%=FormatCurrency(rs("Price"))%>
<%=FormatCurrency(rs("SpecialPrice"))%><%else%><%=FormatCurrency(rs("Price"))%><%end if%>

<% if ParentCode<>"" and ParentCode<>prodcode then %>

Variation

<% rs2.open "SELECT * FROM Products where ParentCode='" & ParentCode & "' and Quantity>0",DBConn,1,3 if not rs2.eof then OptionStr = "" ProdQuantity=rs2("Quantity") %> <% else %> <% OutofStock = true %> <% end if %> <% rs2.close %>

Quantity

<%if ProdQuantity>0 then%> <% else %> <% OutofStock = true %> <% end if %>
<% else %>

Variation

Quantity

<%if rs("Quantity")>0 then%> <% else %> <% OutofStock = true %> <% end if %>
<% end if %>
<%if OutofStock = true then%>Out of Stock<% else %>Add to Basket<% end if%>
<% end if rs.close %>
<% set rs = nothing set rs2 = nothing set fso = nothing DBConn.close set DBConn = nothing %>