RE: [PHP-DB] Double Submission into DB if Hit Refresh

From: Date: Sun, 18 Apr 2004 01:06:08 +0000
Subject: RE: [PHP-DB] Double Submission into DB if Hit Refresh
References: 1  Groups: php.db 
Request: Send a blank email to php-db+get-33944@lists.php.net to get a copy of this message
Hi Add a hidden field into the form with a unique transaction ID. When the data is submitted first time save the transaction ID to a table. Before you do anything check to see if the transaction ID exists in the table, if not then you are ok to save the transaction ID and then add/update the data. If the ID is already there, then do not add/update and send the user a message to say they have submitted the same transaction twice. HTH Peter > -----Original Message----- > From: Craig Hoffman [mailto:choffman@katomic.com] > Sent: 18 April 2004 01:30 > To: php-db@lists.php.net > Subject: [PHP-DB] Double Submission into DB if Hit Refresh > > > What is the best way to avoid data being resubmitted (entered twice) to > DB (mysql) if the user hits refresh after POSTING data via a form? > __________________________________ > Craig Hoffman - eClimb Media > > v: (847) 644 - 8914 > f: (847) 866 - 1946 > e: choffman@eclimb.net > w: www.eclimb.net > _________________________________ > > -- > PHP Database Mailing List (http://www.php.net/) > To unsubscribe, visit: http://www.php.net/unsub.php > >

« previous php.db (#33944) next »