RE: [PHP-DB] how to clear variabeles
| From: | Daevid Vincent | Date: | Tue, 27 Jun 2000 20:54:59 +0000 |
| Subject: | RE: [PHP-DB] how to clear variabeles | ||
| References: | 1 | Groups: | php.db |
| Request: | Send a blank email to php-db+get-673@lists.php.net to get a copy of this message | ||
you could also just manually go through and set the variables to "" after
you insert them into the db...
then the form is blank and a duplicate post would 'error' and you can check
for that.
the only problems so far are some idiot user using the 'back button' on
their browser. the only way to get around that, that I know of is to check
the db to see if that record exists before inserting... there is a "REPLACE
INTO" SQL statement that works like a combo of INSERT and UPDATE, it
"inserts data into a table, replacing any old data that conflicts" that may
be of help.
> -----Original Message-----
> From: Eelco de Graaff [mailto:eelco@tri-angle.demon.nl]
> Sent: Tuesday, June 27, 2000 8:47 AM
> To: php-db@lists.php.net
> Subject: [PHP-DB] how to clear variabeles
>
>
> Hi, i have created a php based form, data is posted to the mysql
> database. I
> have found that it is possible to do 2 postings to the database with the
> same data. Is there a function or a way to clear al the
> variabeles after the
> mysql_query function to make shure data is not duplicated posted?
>
>
>
> --
> PHP Database Mailing List (http://www.php.net/)
> To unsubscribe, e-mail: php-db-unsubscribe@lists.php.net
> For additional commands, e-mail: php-db-help@lists.php.net
> To contact the list administrators, e-mail: php-list-admin@lists.php.net
>