%@ Language=VBScript %> <% '************************************************************************* ' DO NOT MODIFY THIS SCRIPT IF YOU WANT UPDATES TO WORK! ' Function : "Home" Page for Store Front ' Product : CandyPress Store Frontend ' Version : 2.4 ' Modified : June 2003 ' Copyright: Copyright (C) 2003 ShoppersUSA.com ' See "license.txt" for this product for details regarding ' licensing, usage, disclaimers, distribution and general ' copyright requirements. If you don't have a copy of this ' file, you may request one at design@ShoppersUSA.com '************************************************************************* 'Option explicit Response.Buffer = true %> <% 'Database dim mySQL dim conntemp dim rstemp dim rstemp2 'Session dim idOrder dim idCust '************************************************************************* 'Open Database Connection call openDB() 'Store Configuration if loadConfig() = false then call errorDB(langErrConfig,"") end if 'Get/Set Cart/Order Session idOrder = sessionCart() 'Get/Set Customer Session idCust = sessionCust() 'Get/Set Affilate ID call getIdAffiliate(Request.QueryString("idAff")) %> <% 'Close Database Connection call closeDB() '********************************************************************** 'Main Shopping Cart Display Area. '********************************************************************** sub cartMain() dim intDocumentID dim strTitle dim strContent dim adoCn dim strSQL set adoCn = Server.CreateObject("ADODB.Connection") adoCn.Open connstring mySQL = "SELECT documentid, strcategory,title,content " _ & "FROM documents " _ & "WHERE strparentid = 0" set rsTemp = openRSexecute(mySQL) if not rsTemp.eof then mm_documentid = rsTemp("documentid") end if closeRS(rsTemp) intDocumentID = Request.QueryString("documentid") documentid = intDocumentid if isnull("intDocumentid") or request.querystring("documentid")="" then intdocumentid=mm_documentid documentid = mm_documentid end if if not isnumeric(intDocumentID) or intDocumentID = "" then response.redirect "../scripts/sysMsg.asp?errMsg=" & server.URLEncode("Invalid Record id") end if dim adoRs set adoRs = Server.CreateObject("ADODB.Recordset") strSQL = "Select * From Documents where DocumentID=" & intDocumentID set adoRs = adoCn.Execute(strSQL) If not adoRs.EOF then strTitle = adoRs("Title") strContent = adoRs("Content") strPageProperties = adoRs("PageProperties") strdatecreated = adoRs("DateCreated") strparentid = adoRs("strparentid") strparentid2 = strparentid End If adoRs.Close set adoRs = nothing adoCn.Close set adoCn = nothing %>
<% mySQL = "SELECT documentid, strcategory,title,content " _ & "FROM documents " _ & "WHERE strparentid = " & validSQL(intdocumentid,"I") set rsTemp = openRSexecute(mySQL) if not rsTemp.eof then redocumentid = rsTemp("documentid") retitle = rsTemp("title") %>
<% end if do while not rsTemp.eof Response.Write " |