Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 3 of 3

Thread: spam prevent

  1. #1
    New Coder
    Join Date
    Jan 2007
    Posts
    42
    Thanks
    4
    Thanked 0 Times in 0 Posts

    Question spam prevent

    hi
    i have a script on my site that will let people email other members is there anyway i can have a timer on it so after some one sends a message they will have to wait 1 minute to send another message?

  • #2
    New Coder
    Join Date
    Oct 2006
    Posts
    38
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Well, you add a parameter (collumn) to your database called: "last_minute_sent". Then, you send a query that gets that parameter from the database. Then, you compare it with the acual time...
    PHP Code:
    if ($last_minute_sent time(m)) { $error true$response "Wait another minute, please."header(redirect somewhere...);}
    else 
    sendMessage(); 

    Shaffer.

  • #3
    New Coder
    Join Date
    Jan 2007
    Posts
    42
    Thanks
    4
    Thanked 0 Times in 0 Posts

    Question Shaffer

    hi Shaffer
    i don't understand is this all the code i will need?and all i need for the database?sorry im some what new to this thanks


  •  

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •