Multiple Orders

Results 1 to 3 of 3

Thread: Multiple Orders

  1. #1
    Jens Janson Guest

    Default Multiple Orders

    I have only used ASP for 3 days now so please, I need help with this... Here&#039s the deal:<BR><BR>I have done an order page in asp were customers can make their order by marking a checkbox for each product they want and then click a send button.. All checkboxes have the same name but different values created by the db that the products are in. The send button sends the value of all marked checkboxes to order.asp with a "querystring" that looks something like this "/order.asp?id=productname"..<BR><BR>What I want to do next is to list all the marked products with name and price and then the customer confirms the order by entering his/her name and adress in a form and then send the order by email..<BR><BR>All of this works fine.... If only ONE product is bought... Otherwise the "querystring" looks like "/order.asp?id=productname1&id=productname2".. And the page I get is completely blank (no error messages)...<BR><BR>How can I make this work with multiple orders?? <BR><BR>The order.asp page looks like this:<BR><BR>&#060;%<BR>ConnString= "DRIVER={Microsoft Access Driver (*.mdb)};DBQ=" & Server.MapPath("database.mdb")<BR>Set conn = Server.CreateObject("ADODB.Connection")<BR>Set rs = Server.CreateObject("ADODB.RecordSet")<BR><BR>Set order = Request.QueryString("id")<BR>strSQL = "SELECT * FROM Tablename WHERE Name=&#039"& order &"&#039 ORDER BY Title"<BR><BR>conn.Open ConnString<BR>rs.Open strSQL, conn<BR><BR>Do While Not rs.EOF<BR><BR>%&#062;<BR>&#060;%=Rs("name")%&#062; <BR>&#060;%=Rs("price")%&#062;<BR><BR>&#060;%<BR>r s.MoveNext<BR>Loop<BR><BR>rs.Close<BR>Set rs = Nothing<BR>conn.Close<BR>Set conn = Nothing<BR>%&#062;<BR><BR>Please help me solve this.. Thanx in advance /Jens

  2. #2
    Dhana Guest

    Default RE: Multiple Orders

    Hi there,<BR> u shouldn;t use query string for this. U have to submit the page, while submitting loop thru all the elements ( using the forms collection) and findout the products selected by the client and update the database

  3. #3
    Join Date
    Dec 1969

    Default RE: Multiple Orders

    Could you give me some example code on that? I&#039m Cut&#039N&#039Paste learning..

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts