Forum Moderators: coopster
If a contact form has been filled out, then a cookie is set for a certain length of time that disables the submit button on the form, or gets rid of it completely with another message there.
Obviously if the cookie has expired or doesn't exist, then the page displays as normal?
How would i go about this? I've only just this past few minutes looked into cookies while looking at logon pages, and just had this idea. So i'm clueless about it all..any good pointers or tutorials out there to get me started?
:)
lets see...
setcookie('cookie_name', $somevalue, $time+180, '/', 'www.example.com');
the above cookie is valid/active for 180 sec = 3 mins
in your form:
if (!isset($_COOKIE['cookie']))
{
// show submit button
}
else
{
// show some message
}
I think something like this could work