|
There are a couple ways you could go about this.
1) Make it so that when the user clicks the 'submit' button, it creates a session. If the user attempts to click the 'submit' button again after that, the script will check and see if that user has any sessions, and if so, it won't send the message. The downside is that after a while, these sessions expire. They also create additional strain (though insignificant) for the server.
2) Make it so that when the user clicks the 'submit' button the script writes the user's IP address to a .txt file (not quite my classification of a database). If the user attempts to click the 'submit' button again after that, the script will check the .txt file for their IP address, and if it's in there, it won't send the message.
I'd recommend option 2.
__________________
if($stevej == "helpful") { $talkupation += $user_power; }
|