By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
459,380 Members | 1,621 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 459,380 IT Pros & Developers. It's quick & easy.

Back button and a Post form

P: n/a
Hi everbody,

Situation
I created webpage with a receipt with javascript so when someone
orders something from a product list a item is registered on the
receipt. This works fine now.

The next thing which i created is that the receipt works over multiple
pages. So when someone pushes a link i read some hiddenfields
(generated with javascript) into sessionvariables and a redirect to
proper page has been done. The sessionvariables are read, put into a
javascriptarray and are shown in the receipt

The problem
In short the back button (and the refresh button). Off course when
someone chooses the products and pushes back, the hidden fields are
not read by my "session handler". consequence is that the chosen
products are not shown in the receipt.

Help
What can i do? What are my options? Could i put the session handler in
the history? But then a POST (submit) must happen because the hidden
fields are in a form.

I had this problem earlier with another website but then it wasn't
that annoying but now it's not acceptable for me and i want to find a
solution for this.

I saw on a website that, i think, was also created with javascript,
and every action is in the history registered somehow....

Greetz,
Hennie
Jul 20 '05 #1
Share this Question
Share on Google+
1 Reply


P: n/a
Hennie de Nooijer wrote on 15 jul 2003 in comp.lang.javascript:
The problem
In short the back button (and the refresh button). Off course when
someone chooses the products and pushes back, the hidden fields are
not read by my "session handler". consequence is that the chosen
products are not shown in the receipt.


Address the sourse of the problem, which is the design of your page, not
the backability.

For instance, try to refresh from the server and use server variables to
detect the state and redirect when necessary.
Hangt af van je server programmeerbaarheid.

--
Evertjan.
The Netherlands.
(Please change the x'es to dots in my emailaddress)
Jul 20 '05 #2

This discussion thread is closed

Replies have been disabled for this discussion.