T
tony collier
Hi all
I have a shopping cart which I have had to use querystrings to
add/remove items rather than a form. for example, i have a page with a
list of items and next to each one is a button which when clicked refers
to the same page with a different querystring item=12, item=33 etc.
My pageload routine then checks for any query strings and if it finds an
item value, adds this to the respective session variable.
My problem is that if a client adds an item, goes to checkout or any
other page for that matter, then decides to go back in the browser to
the itemlist page, the item gets added again because the querystring is
reloaded along with the page.
Any ideas how I can make sure that items are only added/removed when the
referrer is the same page?
thanks.
I have a shopping cart which I have had to use querystrings to
add/remove items rather than a form. for example, i have a page with a
list of items and next to each one is a button which when clicked refers
to the same page with a different querystring item=12, item=33 etc.
My pageload routine then checks for any query strings and if it finds an
item value, adds this to the respective session variable.
My problem is that if a client adds an item, goes to checkout or any
other page for that matter, then decides to go back in the browser to
the itemlist page, the item gets added again because the querystring is
reloaded along with the page.
Any ideas how I can make sure that items are only added/removed when the
referrer is the same page?
thanks.