It doesn't help to reset any values. The form data is being resent by
the browser itself, just if the user presses the submit button again
with the same data.
What you could do is mabye use a session to see if the particular user
has sent form data before.
/Fredrik Thunberg
Beauford skrev:
El Fri, 12 Jan 2007 03:27:12 -0500
Beauford [EMAIL PROTECTED] escribió:
Hi,
How do I stop contents of a form from being readded to the database
if the user hits the refresh button on their browser.
I have tried to unset/destroy the variables in several different
ways, but it still does
Beauford wrote:
Hi,
How do I stop contents of a form from being readded to the database if the
user hits the refresh button on their browser.
Perhaps a session variable that is set once the form is submitted.
Depending on the data you could also look at having a primary key in the
database.
This issue comes over and over again. The trick, as I learned from this
list, is to send a redirect to the browser to a confirmation page, so the
browser remembers the page redirected to and completely ignores the page
that made the redirection so that neither a refresh nor going back to it
confused as to why giving them a null value doesn't work.
Thanks to all.
-Original Message-
From: Satyam [mailto:[EMAIL PROTECTED]
Sent: January 12, 2007 8:21 AM
To: Beauford; PHP
Subject: Re: [PHP] Forms and destroying values
This issue comes over and over again. The trick
again.
Hope that makes it clearer.
-Stut
-Original Message-
From: Satyam [mailto:[EMAIL PROTECTED]
Sent: January 12, 2007 8:21 AM
To: Beauford; PHP
Subject: Re: [PHP] Forms and destroying values
This issue comes over and over again. The trick, as I
learned from this list, is to send
On Fri, 2007-01-12 at 11:23 -0500, Beauford wrote:
So the answer is, there is no way to destroy the values. Question then, what
is unset() used for as it doesn't seem to do anything? With a language as
good as PHP I though there would be some way to do this. I have got a
workaround, but
Subject: Re: [PHP] Forms and destroying values
This issue comes over and over again. The trick, as I
learned from this list, is to send a redirect to the browser
to a confirmation page, so the browser remembers the page
redirected to and completely ignores the page that made
On Fri, 2007-01-12 at 17:36 +0100, Németh Zoltán wrote:
Beauford,
The unset() function is for session variables, which are remembered by
the server even after the script finished running, that's their
purpose. Your variables are not session variables but normal
variables.
Wrong! Please go
2007. 01. 12, péntek keltezéssel 11.43-kor Robert Cummings ezt írta:
On Fri, 2007-01-12 at 17:36 +0100, Németh Zoltán wrote:
Beauford,
The unset() function is for session variables, which are remembered by
the server even after the script finished running, that's their
purpose. Your
transaction.
Satyam
- Original Message -
From: Beauford [EMAIL PROTECTED]
To: 'PHP' php-general@lists.php.net
Sent: Friday, January 12, 2007 5:23 PM
Subject: RE: [PHP] Forms and destroying values
So the answer is, there is no way to destroy the values. Question then,
what
Message-
From: Stut [mailto:[EMAIL PROTECTED]
Sent: January 12, 2007 11:38 AM
To: Beauford
Cc: 'PHP'
Subject: Re: [PHP] Forms and destroying values
Beauford wrote:
So the answer is, there is no way to destroy the values. Question
then, what is unset() used for as it doesn't seem to do
12 matches
Mail list logo