chris_angell
04-25-2005, 03:50 PM
Hello..
I am making a shopping cart.. I have no problem displaying products in a basket, passing over details is no problem from a products page. but I am stuck what to do after this.. ?? what is the best way to store this info. I have given sessions ago but i am just after a bit of advice before going ahead with this option.
this is what I have tried when storing to a session ?? i think I am doing it wrong.
link to basket from products,,, for example
addbasket.asp?id=12&name=name&price=price
now on the basket page
productNewSession = request.querystring("Id")
productName = request.querystring("name")
productPrice = request.querystring("price")
Session(productNewSession) = productNew + productName + productPrice
then display the the session ie...
Session("productNewSession")
is there a way to group a bunch of session vars under one name and call the values ie
Session("productNewSession").price the do something like
Session("productNewSession").price + 1
:confused:
i was going to use a new session for each product, i know this is wrong but I can't think how I can store the basket info ??
can I make a basket using a database ?? because I know how to add remove update record quite easily.. sessions are confusing me... all i need to do is add records to a session.. call the records, change the quantity and then pass this info on ???
any help ......... or any advice... I am pretty competent at asp but I have never really used sessions or applications.. ??
many thanks... hope this all makes scense........
I am making a shopping cart.. I have no problem displaying products in a basket, passing over details is no problem from a products page. but I am stuck what to do after this.. ?? what is the best way to store this info. I have given sessions ago but i am just after a bit of advice before going ahead with this option.
this is what I have tried when storing to a session ?? i think I am doing it wrong.
link to basket from products,,, for example
addbasket.asp?id=12&name=name&price=price
now on the basket page
productNewSession = request.querystring("Id")
productName = request.querystring("name")
productPrice = request.querystring("price")
Session(productNewSession) = productNew + productName + productPrice
then display the the session ie...
Session("productNewSession")
is there a way to group a bunch of session vars under one name and call the values ie
Session("productNewSession").price the do something like
Session("productNewSession").price + 1
:confused:
i was going to use a new session for each product, i know this is wrong but I can't think how I can store the basket info ??
can I make a basket using a database ?? because I know how to add remove update record quite easily.. sessions are confusing me... all i need to do is add records to a session.. call the records, change the quantity and then pass this info on ???
any help ......... or any advice... I am pretty competent at asp but I have never really used sessions or applications.. ??
many thanks... hope this all makes scense........