Jump to content


multiple form submittion

  • Please log in to reply
No replies to this topic

#1 CanMan2004

  • Members
  • PipPipPip
  • Advanced Member
  • 254 posts

Posted 02 September 2006 - 02:28 PM


I have a php form which sends data to a sql database, I perform the sql query with a $_GET action

The form does a GET and posts the data in the URL like


the php code I then use is

if ($_GET['action'] == 'add')
INSERT INTO .........

Once the INSERT is done, the user is directed to another page, the problem is that because the form method is set to GET, when the user clicks the back button, the GET action and data that was sent from the form is in the URL and the form data is submitted again.

Is there a way to distroy the GET data from the form or know if a user has clicked the back button.

Any help would be great

Thanks in advance


0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users