View Full Version : asp, problem such as shopping cart
11-23-2007, 09:10 AM
hallo all..i got some problem in using the session in ASP. i hope u all can guide me in detail.
i have a form, inside got 3 drop down and one text box. and got one Add button. wat i wan to do is:
after fill in the value for this form, then click the add button and it will display the value in the 2nd page. the data hasnt insert into the database yet. then when user click on continue button in the 2nd page, it can add another new record , etc...until the user click on the FINISH button on the 2nd page, then all the records will insert into DB. it is same as the shopping cart ...but i duno how is work?
can someone plz teach me how to keep the record from the form as session? how is it work ..plz help....
11-23-2007, 09:45 AM
To store the field in a session variable:
Session("InsertVariableName") = Request.Form("InsertFormFieldName")
To display the session variable:
Further information can be found at: W3Schools.com (http://www.w3schools.com/asp/asp_ref_session.asp)
11-23-2007, 01:48 PM
hi DakotaChick , can tell me more?
how can i continuous add the product without submit into database ? i wan to do , when i add 1st product, it weill display the product name, price, quantity at the 2nd page. then i continue to add more products, every time add one product, the 2nd page will add up the products price total. how can i do that? plz help..plz..thank you.
11-24-2007, 05:39 PM
halo there..i need some help in this problem.
i have a form for users to choose which product to order. inside this form , consists of 3 select drop down, every drop down will store the product id, priceid and promotionid. and then have another text box is to fill in the quantity. here have two button, one is calcualte the total amout of the product price * quantity and another button is Add..when the users click on the add button, it will go to the next page which will display the products info that the user has choose. if the user go back to the form page and choose another products, then the second page will add on one row for the new product choose and the total price = first product total price+the second product total price and so on.....in the second page have one Check out button, where..when the user click on it. all the product infor will insert into the database...may i know how to do the coding about this? how cna i use the cookies? can someone plz help me to start the coding? how to store the multiple value from the form in the cookies ?and then how can retireve each of it? plz help..i m poor on this..hope u all can give me some responses..plz..thank you.
Powered by vBulletin® Version 4.2.2 Copyright © 2017 vBulletin Solutions, Inc. All rights reserved.