Advertisement
If you have a new account but are having problems posting or verifying your account, please email us on hello@boards.ie for help. Thanks :)
Hello all! Please ensure that you are posting a new thread or question in the appropriate forum. The Feedback forum is overwhelmed with questions that are having to be moved elsewhere. If you need help to verify your account contact hello@boards.ie
Hi there,
There is an issue with role permissions that is being worked on at the moment.
If you are having trouble with access or permissions on regional forums please post here to get access: https://www.boards.ie/discussion/2058365403/you-do-not-have-permission-for-that#latest

prevent mass emails from your website

  • 07-07-2006 1:09pm
    #1
    Closed Accounts Posts: 1,200 ✭✭✭


    Lately there are a lot of email coming trough from the websites using remote access to you form.
    It happened to me as well. Got about 100 email in 20 min, so what i did was to create a session and if bigger then 2 (no more then 2 email per session) i redirect them to the home page.
    If anybody find it usefull you are more then welcome to use it.
    Is in php but can be easily converted to any language.

    if you have a global include file like top.php add this to it:
    //block mass email senders
    // change this to you variable :: (@$_POST["sendemail"] == '1' ::
    if (@$_POST["sendemail"] == '1') {
     $_SESSION['you_send_email'] = @$_SESSION['you_send_email']+1;  
    }
    //end of block mass email senders
    

    then on the page with the form add this before the email execute code:
    //block mass email senders
    if (@$_SESSION['you_send_email'] > 2){
     $_SESSION['you_send_email'] == 2;
      header("Location: [URL="http://www.yourdomainname.tld/index.php"]http://www.yourdomainname.tld/index.php[/URL]");
     exit(); 
    }
    //end of block mass email senders
    

    hope this help anybody


Advertisement