form to mail question

Get help on web editors (Frontpage, Dreamweaver) and web languages (HTML, ASP, PHP).
Post Reply
jamescells
Registered User
Posts: 9
Joined: 24 Sep 2002, 02:00
Location: Johannesburg
Contact:

form to mail question

Post by jamescells »

Hi there

Just a quick question - how would i be able to autmatically clear the form once submitted so that if they click on back it doesnt keep their info in the form? Im running competitions and it just makes it so easy for people to enter 400 times in a hour. :roll:
maxxis
Moderator Emeritus
Posts: 8307
Joined: 30 Jun 2004, 02:00
Location: ( . Y . )
Contact:

Post by maxxis »

Hi there and welcome to the forums.

What you need to do is to have the result page create a cookie on the users machine. A simple random or sequential number. This same number will be stored in a database to enable validation .

Step 2 is to add a validation to your form that reads the cookie from the users pc and checks it with the database before submitting the form.

Step 3. If the cookie exists in the database and the users pc then the user is informed that he has filled in the form already and that he needs to fill it in again before submitting it.

Hope this helps
jamescells
Registered User
Posts: 9
Joined: 24 Sep 2002, 02:00
Location: Johannesburg
Contact:

Post by jamescells »

Sounds like a plan.. thanks
Post Reply