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

Help with Back button

P: 1
Hi all,

I have a site it goes like this

Front Page Add to cart button ->
Page with an onload auto-submit form through JS ->
View Cart

When they click the back button from view cart, it brings them back to the auto-submit form which in turn brings them back to the View Cart page with another item added because the form is submitted again.

I have to do it this way to convert an <a href with a ?str to a post form.

I am using PHP 5 =)

Any ideas you all have would be excellent =)

Light and Love and Healing Peace Propserity JOy and Abundance to you all,
-Patrick Arden McNally
Jan 31 '08 #1
Share this Question
Share on Google+
1 Reply

Expert Mod 15k+
P: 16,027
Hi Patrick, welcome to TSDN!

Try using a post-redirect model, i.e. once the form is posted, it is redirected, so when the user presses back they avoid a double post. It will also avoid the popup that asks for confirmation about posting again.
Jan 31 '08 #2

Post your reply

Sign in to post your reply or Sign up for a free account.