Re: I don't want multiple form submitted

From: Date: Thu, 26 Sep 2002 23:16:25 +0000
Subject: Re: I don't want multiple form submitted
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-117792@lists.php.net to get a copy of this message
You could also do a simple data check against your database to make sure that the same information isn't posted by the same person in a certain time period. More complicated, but works well and doesn't rely on browser refresh or php headers - both of which can occasionally run into problems. Best Regards Bob Irwin Server Admin & Web Programmer Planet Netcom ----- Original Message ----- From: "John Holmes" <holmes072000@charter.net> To: "'Clemson Chan'" <clemsonchan@earthlink.net>; "'Php'" <php-general@lists.php.net> Sent: Friday, September 27, 2002 9:13 AM Subject: RE: [PHP] I don't want multiple form submitted > > I have a message board written in PHP w/MySQL. > > So when a person submitting a post, it goes to a list_view. > > If this person refresh the list_view. > > The message he submitted will get submitted again. > > How can I avoid this problem? > > Please let me know if you know the answer. Thanks > > This question is asked every week, it seems. Best method is to use a > "middle-man". Use a middle page that processes the new post, then > redirects the user to the next page. You can use a PHP header() > solution, or a javascript META-REFRESH method. > > ---John Holmes... > > > -- > PHP General Mailing List (http://www.php.net/) > To unsubscribe, visit: http://www.php.net/unsub.php > > > Scanned by PeNiCillin http://safe-t-net.pnc.com.au/ > > Scanned by PeNiCillin http://safe-t-net.pnc.com.au/

« previous php.general (#117792) next »