vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 3.7 Add-ons (https://vborg.vbsupport.ru/forumdisplay.php?f=228)
-   -   Administrative and Maintenance Tools - Auto Bounce Messages Management (https://vborg.vbsupport.ru/showthread.php?t=181936)

Milad 06-10-2008 03:28 AM

Quote:

Originally Posted by dtv100 (Post 1545547)
is there any way to know who was move because email bounce ?

Yes, will be added.
Regards

renep 06-10-2008 08:29 AM

Quote:

Originally Posted by Milad (Post 1544851)
If you have a better pattern to suggest, go on.

I couldn't find an authoritative specification, but it seems '+' is universally used as the box+recipient separator, and '=' is used to encode special characters in the recipient address (that may not be unencoded in the bounce address).

By following this pattern, people can use the default VERP-support in their MTA to route bounces to a particular mailbox, which your add-on reads.

You prefer to use an id rather than the recipient address in the bounce address, to avoid abuse. That's fine of course, as long as you encode special characters in the id (in particular '@').

Milad 06-10-2008 10:07 AM

Quote:

Originally Posted by renep (Post 1545675)
You prefer to use an id rather than the recipient address in the bounce address, to avoid abuse. That's fine of course, as long as you encode special characters in the id (in particular '@').

The id that I use, contains a-z0-9 and dot only.

Alfa1 06-14-2008 12:53 PM

Without a message to the inactivated member, this mod will lead to a mass of inquiries. On a large board this is a serious problem.

I know I asked for a lot of features before, but please consider to add an automatic PM.

Quote:

Originally Posted by Alfa1 (Post 1544467)
Many thanks Milad! I am looking forward to future versions.

Please consider to add:
  • different responses to different error codes / Custom filters to match patterns in bounced emails. i.e. permanent error, mailbox full, etc should get a different response. Not many webmasters want their members account inactivated when a mailbox is full.
  • Stats on members with bouncing emails, and error codes
  • Turns on Popup Notification of new Private Messages for bouncing member
  • Automatically send a notification PM to bouncing Member (customizable message)
  • Return members to their original usergroup when the member updates & confirms their new email.


Milad 06-14-2008 03:11 PM

I really have a problem that all suggestion had been copied from previous hacks such as vBouncer.

I don't like to do things already done. anyway the automatic PM notification is on its way to be added. I'm trying to add something new because I want my mod to be unique.

This is the most difficult part:
Quote:

different responses to different error codes / Custom filters to match patterns in bounced emails. i.e. permanent error, mailbox full, etc should get a different response.
Now I'm working on analyzing cron job which will classify the bounce messages. it's gonna take a lot of work and development.

Devices 06-14-2008 05:35 PM

Quote:

Originally Posted by Milad (Post 1549240)
I really have a problem that all suggestion had been copied from previous hacks such as vBouncer.

I don't like to do things already done. anyway the automatic PM notification is on its way to be added. I'm trying to add something new because I want my mod to be unique.

This is the most difficult part:
Now I'm working on analyzing cron job which will classify the bounce messages. it's gonna take a lot of work and development.

I don't think you need to worry about having the same features as Vbouncer as that hack has been unsupported for a long time. Your hack is doing the same job so it is very likely it will have the same or similar features. Also new features will make your addon more unique.

I am glad to hear you are adding in a PM notification also as this is very important. As Alfa1 says it can cuase confusion for any members that have been dealt with.

Alfa1 06-14-2008 08:17 PM

Quote:

Originally Posted by Milad (Post 1549240)
I really have a problem that all suggestion had been copied from previous hacks such as vBouncer.

I don't like to do things already done. anyway the automatic PM notification is on its way to be added. I'm trying to add something new because I want my mod to be unique.

I would not want you to copy anyone's work. Your mod is unique as there is no other working mod that automatically handles bounced mail.

The suggestions are to fill a need that is there. There will be various ways to do so.
Thank you for taking up the suggestion of a PM notification.

Quote:

Originally Posted by Milad (Post 1549240)
This is the most difficult part:
Now I'm working on analyzing cron job which will classify the bounce messages. it's gonna take a lot of work and development.

I can imagine that it will, but you can be sure that we will be grateful for your work. These functions are essential for a healthy site and there is nothing that completely handles it.

In relation to the article in my signature, there is a need to process responses from the SMTP servers of email providers and take appropriate action per response.

I am very grateful for Anti-Virus his EZ bounced management, because until now it was the only thing that helped. Only after a completely automated mod like yours handles this issue I will dare to do a mass emailing.

youradhere4222 06-14-2008 10:31 PM

Quote:

Originally Posted by Milad (Post 1545461)
OK, never mind. I'm sorry for that. I'm going to make the copyright optional.

Thus, I appreciate if you post a backlink to my site. when you announce the automation to your members.

Regards

Thank you.

stwilson 06-15-2008 05:06 AM

Milad,

Thank you for your work and thank you for reconsidering the back links. I will give this a try and if it works for me I will NOT put on a back link (I don't use any MODs that require back links) but rather I will send you money for your efforts. Thanks for contributing to the VB community!!!!! Keep up the great work!!

stwilson 06-17-2008 03:12 AM

Milad,

I have installed without issue. I modifed a user account with a bogus email address but the account was not moved to the prescribed user group. I have a catch-all email account in my setup, one that will take any email address for the domain. Any suggestions?

stwilson 06-17-2008 03:13 AM

I forgot to mention that I used the Admin account to private message the account that I updated with the bogus email address. The test account is setup to send an email notification of a new private message. I see the bounced email in the catch-all email account but the user group was not modified.

RedTrinity 06-17-2008 04:21 AM

When will the version with optional copyright be released?

Zachery 06-17-2008 06:30 PM

for the plugin you can disable the parse_templates hook and it will remove the copyright.

stwilson 06-18-2008 02:46 AM

Has anyone else gotten this MOD to work? I installed OK but user accounts are not being moved upon receipt of a bounce.

Milad 06-18-2008 04:00 AM

Quote:

Originally Posted by stwilson (Post 1552246)
Has anyone else gotten this MOD to work? I installed OK but user accounts are not being moved upon receipt of a bounce.

Did you configure your POP settings?

If not do it and use the test POP connection link to make sure that the mod can connect to the POP mail.

Regards

stwilson 06-18-2008 04:08 AM

Yes, I did. The test connection part works. Here is what it shows (I replaced my real text with mydomain):

Connecting to mail.mydomain.com ...
S +OK mail.mydomain.com My Domain Mail Server POP3 Wed, 18 Jun 2008 06:05:25 +0100 <20080618060525@mail.mydomain.com>
Connected to the POP3 server "mail.mydomain.com".
C USER bounced@mydomain.com
S +OK bounced@mydomain.com
C PASS mypass
S +OK 2 messages (5510) octets
User "bounced@mydomain.com" logged in.
C STAT
S +OK 2 5510
There are 2 message(s) in the mail box with a total of 5510 bytes.

Again, everything appears to be setup correctly. Can you tell me what CRON jobs should be found in my CRON job list? I don't think they are running.

Milad 06-18-2008 04:38 AM

You will find one cron job with clear name, try to run it.

Regards

alessai 06-18-2008 10:10 AM

Milad thanx for the addon and i'll try it later

for now i marked it as installed

J3rico 06-20-2008 05:15 AM

Quote:

Originally Posted by stwilson (Post 1552276)
Yes, I did. The test connection part works. Here is what it shows (I replaced my real text with mydomain):

Connecting to mail.mydomain.com ...
S +OK mail.mydomain.com My Domain Mail Server POP3 Wed, 18 Jun 2008 06:05:25 +0100 <20080618060525@mail.mydomain.com>
Connected to the POP3 server "mail.mydomain.com".
C USER bounced@mydomain.com
S +OK bounced@mydomain.com
C PASS mypass
S +OK 2 messages (5510) octets
User "bounced@mydomain.com" logged in.
C STAT
S +OK 2 5510
There are 2 message(s) in the mail box with a total of 5510 bytes.

Again, everything appears to be setup correctly. Can you tell me what CRON jobs should be found in my CRON job list? I don't think they are running.

hi, same problem for me, check is ok, but user group was not modified.

Milad 06-20-2008 05:37 AM

try to run the cron job: bounces_retrieve.php and copy what messages it will print!

J3rico 06-20-2008 06:56 AM

hi, thank's for the answer, i have the cron retrievebounces.php (this file is included in the zip file), when run i get this message :

Code:

ABMM: Retrive Bounces
Connected to the POP3 server "pop.gmail.com".
User "myuser@gmail.com" logged in.
There are no new bounces!
Disconnected from the POP3 server "pop.gmail.com".

Eseguito

thank's :)

Milad 06-20-2008 11:24 AM

If the bounce messages are still in your gmail account, please open one of them and look for the "Show original" link in the drop-down menu at the upper right corner.

Please copy and paste the content here.

Regrads.

J3rico 06-20-2008 12:14 PM

Code:

Delivered-To: myaccount@gmail.com
Received: by 10.141.20.5 with SMTP id x5cs125266rvi;
        Thu, 19 Jun 2008 10:55:10 -0700 (PDT)
Received: by 10.141.151.18 with SMTP id d18mr6810126rvo.152.1213898110434;
        Thu, 19 Jun 2008 10:55:10 -0700 (PDT)
Received-SPF: softfail (google.com: domain of transitioning unknown does not designate 65.54.246.91 as permitted sender) client-ip=65.54.246.91;
Received: by 10.140.83.37 with POP3 id g37mf110384rvb.6;
        Thu, 19 Jun 2008 10:55:10 -0700 (PDT)
X-Gmail-Fetch-Info: postmaster@mysite.it 1 mail.mysite.it 110 postmaster@mysyte.it
Return-Path: <>

X-Spam-Checker-Version: SpamAssassin 3.1.7-deb (2006-10-05) on IT20-MAIL
X-Spam-Level: ***
X-Spam-Status: No, score=3.0 required=5.5 tests=BAYES_00,DATE_IN_PAST_06_12,
        FORGED_HOTMAIL_RCVD,FRONTPAGE,HTML_IMAGE_RATIO_02,HTML_MESSAGE,
        HTML_TAG_BALANCE_BODY,NO_REAL_NAME autolearn=no version=3.1.7-deb
Delivered-To: mysyte.it-postmaster@mysyte.it
Received: (qmail 14689 invoked by uid 0); 19 Jun 2008 19:45:01 +0200
Received: from unknown (HELO bay0-omc1-s19.bay0.hotmail.com) (65.54.246.91)
  by xxx.xxxxxxxx.net with SMTP; 19 Jun 2008 19:45:01 +0200
Received: from BAY106-W35 ([65.54.161.135]) by bay0-omc1-s19.bay0.hotmail.com with Microsoft SMTPSVC(6.0.3790.3959);
        Thu, 19 Jun 2008 10:44:56 -0700
Message-ID: <BAY106-W35453E691116F447678B16BAAA0@phx.gbl>
From: postmaster@mail.hotmail.com
To: postmaster@mysyte.it
Date: Thu, 19 Jun 2008 10:44:56 GMT
MIME-Version: 1.0
Content-Type: multipart/report; report-type=delivery-status;
        boundary="9B095B5ADSN=_98C9A2A81C354B9EB49533476B1?WOM1.labinte"
X-DSNContext: 7ce717b1 - 1196 - 00000002 - 00000000
Subject: Delivery Status Notification (Failure)
Return-Path: <>
X-OriginalArrivalTime: 19 Jun 2008 17:44:56.0485 (UTC) FILETIME=[2FF61D50:01C8D234]

This is a MIME-formatted message. 
Portions of this message may be unreadable without a MIME-capable mail program.

--9B095B5ADSN=_98C9A2A81C354B9EB49533476B1?WOM1.labinte
Content-Type: text/plain; charset=unicode-1-1-utf-7

This is an automatically generated Delivery Status Notification.

Delivery to the following recipients failed.

      user@hotmail.com




--9B095B5ADSN=_98C9A2A81C354B9EB49533476B1?WOM1.labinte
Content-Type: message/delivery-status

Reporting-MTA: dns;imc2-s4.hotmail.com
Received-From-MTA: dns;wim1-s4.hotmail.com
Arrival-Date: Thu, 19 Jun 2008 10:41:56 GMT

Final-Recipient: rfc822;user@hotmail.com
Action: failed
Status: 5.5.0
Diagnostic-Code: smtp;550 Requested action not taken: mailbox unavailable

--9B095B5ADSN=_98C9A2A81C354B9EB49533476B1?WOM1.labinte
Content-Type: message/rfc822

X-Message-Delivery: Vj0zLjQuMDt1cz0wO2w9MDthPTE=
X-Message-Status: n:0
X-SID-PRA: postmaster@mysyte.it <postmaster@mysyte.it>
X-Message-Info: JGTYoYF78jGyls5/72tozajnpJwPuqZsfwVQyN/kbtbDSBaIM9Z9PbGtyFD0pdXELKDRxAtOj1lG5Umu5so6+Q==
Received: from it11.xxxxxxxx.net ([xxx.x.xxx.xx]) by bay0-mc5-f6.bay0.hotmail.com with Microsoft SMTPSVC(6.0.3790.2668);
        Thu, 12 Jun 2008 14:10:20 -0700
Received: by it11.xxxxxxxx.net (Postfix, from userid 33)
        id 615B9489A1; Thu, 12 Jun 2008 23:10:19 +0200 (CEST)
To: user@hotmail.com
Subject: TomTom GO920T ad un prezzo speciale solo da Youbuy
From: "postmaster@mysyte.it" <postmaster@mysyte.it>
Message-ID: <20080612211019.5f0801817254@www.mysyte.it>
MIME-Version: 1.0
Content-Type: text/html; charset="UTF-8"
Content-Transfer-Encoding: 8bit
X-Priority: 3
X-Mailer: vBulletin Mail via PHP
Date: Thu, 12 Jun 2008 23:10:19 +0200 (CEST)
Return-Path: postmaster@mysyte.it
X-OriginalArrivalTime: 12 Jun 2008 21:10:21.0275 (UTC) FILETIME=[B93792B0:01C8CCD0]

Best regards :)

Milad 06-21-2008 05:02 AM

This message didn't return to the bounce email (ex: bounce20080608103128.551e45224330@yourdomain.ext), it seems like it had been sent before you install the product.

Would you please copy and paste one of your sent messages (while the hack enabled) to see how they look?

booktoweb 06-22-2008 12:43 PM

thanks milad
i had make registration without activation by mail from 1 year
because i have a problem in yahoo mail ( it send to bulk mail )
so i will now ban yahoo mail from register
and return the activation to work
after this i will using your Product to manage all bad members that register with not valid mail

Milad 06-22-2008 03:25 PM

Don't be in a hurry and wait for the next beta.

Sym0n 06-28-2008 06:12 AM

Really interested in this, but I'm waiting for a final and preferably supported version.

Sy

stwilson 06-28-2008 05:06 PM

I still have not been able to get this to work. I have the bounced messages in my in-box. Here is the info from the To: field in the bounced message:

bounce20080616052150.d7e1a8553456@myohv.com

But the user's usergroup is never changed to the user group I identified in the MOD CP. Any suggestions?

AngelBlue 07-04-2008 12:53 AM

I've added some code so that bouncing users now get:
* Popup PM notification set to YES
* Receive admin emails set to NO
* Recieve email PM notification set to NO
* Thread subscription mode set to "no email" (if it was previously set to instant, daily or weekly email)
* All their thread and forum subscriptions set to 'no email'.
* A PM to explain the above.

To do this, I replaced the code in your "Move Users To Bounce Usergroup" plugin with this:

Code:

$bounces = $vbulletin->db->query_read("
        SELECT messageid, toemail
        FROM " . TABLE_PREFIX . "sent_email
        WHERE bounced = 1
");

if ($vbulletin->db->num_rows($bounces) > 0)
{
        $toemails = array();
        $messageids = array();
       
        while ($bounce = $vbulletin->db->fetch_array($bounces))
        {
                $toemails[] = "'" . $bounce['toemail'] . "'";
                $messageids[] = $bounce['messageid'];
        }
        $toemails = array_unique($toemails);

        // start added code here... define data for PM data manager

        $tonames = array();
        $touids = array();
        $myuid = 1;
        $fromuser = fetch_userinfo($myuid);
        $message = "We tried to deliver an email to you, but unfortunately, it bounced. To prevent us sending more mail to you while your email provider is not accepting it, we have deactivated all the email-related features of your account. To reactivate your account, go to your UserCP, and update your email address. You will then get a confirmation email. Clicking on the link in this confirmation email should re-enable your account, at which point you will need to visit your UserCP options page to re-enable the email notifications you wish to use.";

        $affected = $vbulletin->db->query_read("SELECT userid,username FROM " . TABLE_PREFIX . "user WHERE email IN (" . implode(', ', $toemails) . ")");
        while ($affected = $vbulletin->db->fetch_array($affected)) {
                $tonames[] = $affected['username'];
                $touids[] = $affected['userid'];
        }
        $tonames = array_unique($tonames);
        $pmdm =& datamanager_init('PM', $vbulletin, ERRTYPE_SILENT);
        $pmdm->set('fromuserid', '1');
        $pmdm->set('fromusername', 'EmailBot');
        $pmdm->set_info('reciept', false);
        $pmdm->set_info('savecopy', false);
        $pmdm->set('title', 'Email Broken!');
        $pmdm->set('message', $message);
        $pmdm->set_recipients(implode(";",$tonames), $fromuser['permissions']);
        $pmdm->set('dateline', TIMENOW);
        $pmdm->save();

       
       
        // this is stock mod code to move them to the different usergroup.
        $vbulletin->db->query_write("UPDATE " . TABLE_PREFIX . "user SET usergroupid = " .  $vbulletin->options['bm_usergroup'] . ", membergroupids = '', displaygroupid = 0 WHERE usergroupid NOT IN (" . $vbulletin->options['bm_excludeusergroups'] . ") AND email IN (" . implode(', ', $toemails) . ")");

        // and stock code to delete their message tracking info...
        $vbulletin->db->query_write("DELETE FROM " . TABLE_PREFIX . "sent_email WHERE messageid IN (" . implode(', ', $messageids) . ")");

        // continue custom code to update their user options...
        // stop them generating any more email!

        // pm popup = YES
        $vbulletin->db->query_write("UPDATE " . TABLE_PREFIX . "user SET pmpopup = 1 WHERE email IN (" . implode(', ', $toemails) . ")");
       
        // send notification email on PM - NO
        $vbulletin->db->query_write("UPDATE " . TABLE_PREFIX . "user SET options = (options - 4096) WHERE (options & 4096) AND email IN (" . implode(', ', $toemails) . ")");

        // admin email OFF
        $vbulletin->db->query_write("UPDATE " . TABLE_PREFIX . "user SET options = (options - 16) WHERE (options & 16) AND email IN (" . implode(', ', $toemails) . ")");

        // set autosubscribe = without email WHERE autosubscribe_with_email
        $vbulletin->db->query_write("UPDATE " . TABLE_PREFIX . "user SET autosubscribe = 1 WHERE (autosubscribe > 1) AND email IN (" . implode(', ', $toemails) . ")");

        // set emailupdates = 0 for their thread subscriptions
        $vbulletin->db->query_write("UPDATE " . TABLE_PREFIX . "subscribethread SET emailupdate = 0 WHERE (emailupdate > 0) AND userid IN (" . implode(', ', $touids) . ")");

        // set emailupdates = 0 for their forum subscriptions
        $vbulletin->db->query_write("UPDATE " . TABLE_PREFIX . "subscribeforum SET emailupdate = 0 WHERE (emailupdate > 0) AND userid IN (" . implode(', ', $touids) . ")");

        // finish
        unset($toemails, $messageids);
}

$vbulletin->db->free_result($bounces);


Hornstar 07-07-2008 11:39 PM

When I test my connection I got this message: 3 POP3 server greeting was not found

What does that mean?

Edit, changed pop host to an ip instead and that worked. Looking forward to the results of this. thanks.


Quote:

Originally Posted by AngelBlue (Post 1566332)
I've added some code so that bouncing users now get:
* Popup PM notification set to YES
* Receive admin emails set to NO
* Recieve email PM notification set to NO
* Thread subscription mode set to "no email" (if it was previously set to instant, daily or weekly email)
* All their thread and forum subscriptions set to 'no email'.
* A PM to explain the above.

To do this, I replaced the code in your "Move Users To Bounce Usergroup" plugin with this:

Code:

$bounces = $vbulletin->db->query_read("
    SELECT messageid, toemail
    FROM " . TABLE_PREFIX . "sent_email
    WHERE bounced = 1
");

if ($vbulletin->db->num_rows($bounces) > 0)
{
    $toemails = array();
    $messageids = array();
   
    while ($bounce = $vbulletin->db->fetch_array($bounces))
    {
        $toemails[] = "'" . $bounce['toemail'] . "'";
        $messageids[] = $bounce['messageid'];
    }
    $toemails = array_unique($toemails);

    // start added code here... define data for PM data manager

    $tonames = array();
    $touids = array();
    $fromuser = fetch_userinfo(1);
    $message = "We tried to deliver an email to you, but unfortunately, it bounced. To prevent us sending more mail to you while your email provider is not accepting it, we have deactivated all the email-related features of your account. To reactivate your account, go to your UserCP, and update your email address. You will then get a confirmation email. Clicking on the link in this confirmation email should re-enable your account, at which point you will need to visit your UserCP options page to re-enable the email notifications you wish to use.";

    $affected = $vbulletin->db->query_read("SELECT userid,username FROM " . TABLE_PREFIX . "user WHERE email IN (" . implode(', ', $toemails) . ")");
    while ($affected = $vbulletin->db->fetch_array($affected)) {
        $tonames[] = $affected['username'];
        $touids[] = $affected['userid'];
    }
    $tonames = array_unique($tonames);
    $pmdm =& datamanager_init('PM', $vbulletin, ERRTYPE_SILENT);
    $pmdm->set('fromuserid', '1');
    $pmdm->set('fromusername', 'EmailBot');
    $pmdm->set_info('reciept', false);
    $pmdm->set_info('savecopy', false);
    $pmdm->set('title', 'Email Broken!');
    $pmdm->set('message', $message);
    $pmdm->set_recipients(implode(";",$tonames), $fromuser['permissions']);
    $pmdm->set('dateline', TIMENOW);
    $pmdm->save();

   
   
    // this is stock mod code to move them to the different usergroup.
    $vbulletin->db->query_write("UPDATE " . TABLE_PREFIX . "user SET usergroupid = " .  $vbulletin->options['bm_usergroup'] . ", membergroupids = '', displaygroupid = 0 WHERE usergroupid NOT IN (" . $vbulletin->options['bm_excludeusergroups'] . ") AND email IN (" . implode(', ', $toemails) . ")");

    // and stock code to delete their message tracking info...
    $vbulletin->db->query_write("DELETE FROM " . TABLE_PREFIX . "sent_email WHERE messageid IN (" . implode(', ', $messageids) . ")");

    // continue custom code to update their user options...
    // stop them generating any more email!

    // pm popup = YES
    $vbulletin->db->query_write("UPDATE " . TABLE_PREFIX . "user SET pmpopup = 1 WHERE email IN (" . implode(', ', $toemails) . ")");
   
    // send notification email on PM - NO
    $vbulletin->db->query_write("UPDATE " . TABLE_PREFIX . "user SET options = (options - 4096) WHERE (options & 4096) AND email IN (" . implode(', ', $toemails) . ")");

    // admin email OFF
    $vbulletin->db->query_write("UPDATE " . TABLE_PREFIX . "user SET options = (options - 16) WHERE (options & 16) AND email IN (" . implode(', ', $toemails) . ")");

    // set autosubscribe = without email WHERE autosubscribe_with_email
    $vbulletin->db->query_write("UPDATE " . TABLE_PREFIX . "user SET autosubscribe = 1 WHERE (autosubscribe > 1) AND email IN (" . implode(', ', $toemails) . ")");

    // set emailupdates = 0 for their thread subscriptions
    $vbulletin->db->query_write("UPDATE " . TABLE_PREFIX . "subscribethread SET emailupdate = 0 WHERE (emailupdate > 0) AND userid IN (" . implode(', ', $touids) . ")");

    // set emailupdates = 0 for their forum subscriptions
    $vbulletin->db->query_write("UPDATE " . TABLE_PREFIX . "subscribeforum SET emailupdate = 0 WHERE (emailupdate > 0) AND userid IN (" . implode(', ', $touids) . ")");

    // finish
    unset($toemails, $messageids);
}

$vbulletin->db->free_result($bounces);


Cool! Any chance of this getting packaged up. I would really love to get this installed on my board. It is now a requirement of AOL that you remove any permanently bounced emails from your mailing list or you risk getting blacklisted.

stwilson 07-16-2008 08:28 AM

Still not able to get this working. I have configured all the settings and have verified the bounced message has the appropriate string in it but the usergroup is not changed, even after the chron job is run manually.

Can anyone confirm this mod has worked for them?

mrahul 07-17-2008 08:32 AM

isn't it possible to track down all emails automatically if the email bounces more than thrice the system stops sending mails to the non-active mails ?

Alfa1 07-17-2008 03:12 PM

If a member is placed into the bounced usergroup and then updates his/her email address, will the member be placed back in his/her original usergroup?

djilou 07-23-2008 12:02 PM

Quote:

3)Another cron job runs once an hour, reads the bounced emails from the database and moves their owners to an usergroup which is determined by the admin from the settings.
4) Yet another cron job, will run once daily, to prune the records that haven't returned bounces in a settable period of time (30 days by default).
Why I don't see those cron jobs on the Scheduled Tasks ??
I see only : ABMM: Retrive Bounces
This Scheduled Task retrieves the bounced emails from the server every ten minutes.

Milad 07-24-2008 04:15 PM

Quote:

Originally Posted by djilou (Post 1582212)
Why I don't see those cron jobs on the Scheduled Tasks ??
I see only : ABMM: Retrive Bounces
This Scheduled Task retrieves the bounced emails from the server every ten minutes.

Two cron jobs run as plug-ins in other cron jobs.

djilou 07-24-2008 08:38 PM

Edit : never mind the cron job didn't work because of this

Quote:

Originally Posted by AngelBlue (Post 1566332)
I've added some code so that bouncing users now get:
* Popup PM notification set to YES
* Receive admin emails set to NO
* Recieve email PM notification set to NO
* Thread subscription mode set to "no email" (if it was previously set to instant, daily or weekly email)
* All their thread and forum subscriptions set to 'no email'.
* A PM to explain the above.

To do this, I replaced the code in your "Move Users To Bounce Usergroup" plugin with this:

Code:

$bounces = $vbulletin->db->query_read("
        SELECT messageid, toemail
        FROM " . TABLE_PREFIX . "sent_email
        WHERE bounced = 1
");

if ($vbulletin->db->num_rows($bounces) > 0)
{
        $toemails = array();
        $messageids = array();
       
        while ($bounce = $vbulletin->db->fetch_array($bounces))
        {
                $toemails[] = "'" . $bounce['toemail'] . "'";
                $messageids[] = $bounce['messageid'];
        }
        $toemails = array_unique($toemails);

        // start added code here... define data for PM data manager

        $tonames = array();
        $touids = array();
        $fromuser = fetch_userinfo(1);
        $message = "We tried to deliver an email to you, but unfortunately, it bounced. To prevent us sending more mail to you while your email provider is not accepting it, we have deactivated all the email-related features of your account. To reactivate your account, go to your UserCP, and update your email address. You will then get a confirmation email. Clicking on the link in this confirmation email should re-enable your account, at which point you will need to visit your UserCP options page to re-enable the email notifications you wish to use.";

        $affected = $vbulletin->db->query_read("SELECT userid,username FROM " . TABLE_PREFIX . "user WHERE email IN (" . implode(', ', $toemails) . ")");
        while ($affected = $vbulletin->db->fetch_array($affected)) {
                $tonames[] = $affected['username'];
                $touids[] = $affected['userid'];
        }
        $tonames = array_unique($tonames);
        $pmdm =& datamanager_init('PM', $vbulletin, ERRTYPE_SILENT);
        $pmdm->set('fromuserid', '1');
        $pmdm->set('fromusername', 'EmailBot');
        $pmdm->set_info('reciept', false);
        $pmdm->set_info('savecopy', false);
        $pmdm->set('title', 'Email Broken!');
        $pmdm->set('message', $message);
        $pmdm->set_recipients(implode(";",$tonames), $fromuser['permissions']);
        $pmdm->set('dateline', TIMENOW);
        $pmdm->save();

       
       
        // this is stock mod code to move them to the different usergroup.
        $vbulletin->db->query_write("UPDATE " . TABLE_PREFIX . "user SET usergroupid = " .  $vbulletin->options['bm_usergroup'] . ", membergroupids = '', displaygroupid = 0 WHERE usergroupid NOT IN (" . $vbulletin->options['bm_excludeusergroups'] . ") AND email IN (" . implode(', ', $toemails) . ")");

        // and stock code to delete their message tracking info...
        $vbulletin->db->query_write("DELETE FROM " . TABLE_PREFIX . "sent_email WHERE messageid IN (" . implode(', ', $messageids) . ")");

        // continue custom code to update their user options...
        // stop them generating any more email!

        // pm popup = YES
        $vbulletin->db->query_write("UPDATE " . TABLE_PREFIX . "user SET pmpopup = 1 WHERE email IN (" . implode(', ', $toemails) . ")");
       
        // send notification email on PM - NO
        $vbulletin->db->query_write("UPDATE " . TABLE_PREFIX . "user SET options = (options - 4096) WHERE (options & 4096) AND email IN (" . implode(', ', $toemails) . ")");

        // admin email OFF
        $vbulletin->db->query_write("UPDATE " . TABLE_PREFIX . "user SET options = (options - 16) WHERE (options & 16) AND email IN (" . implode(', ', $toemails) . ")");

        // set autosubscribe = without email WHERE autosubscribe_with_email
        $vbulletin->db->query_write("UPDATE " . TABLE_PREFIX . "user SET autosubscribe = 1 WHERE (autosubscribe > 1) AND email IN (" . implode(', ', $toemails) . ")");

        // set emailupdates = 0 for their thread subscriptions
        $vbulletin->db->query_write("UPDATE " . TABLE_PREFIX . "subscribethread SET emailupdate = 0 WHERE (emailupdate > 0) AND userid IN (" . implode(', ', $touids) . ")");

        // set emailupdates = 0 for their forum subscriptions
        $vbulletin->db->query_write("UPDATE " . TABLE_PREFIX . "subscribeforum SET emailupdate = 0 WHERE (emailupdate > 0) AND userid IN (" . implode(', ', $touids) . ")");

        // finish
        unset($toemails, $messageids);
}

$vbulletin->db->free_result($bounces);



testebr 07-25-2008 07:53 PM

When will the final version be released?

scsa20 07-28-2008 06:51 AM

I'm trying to set this up and when I test the connection to the pop server, I get the following error message:

110 could not connect to the host "pop.gmail.com": Connection timed out

what am I possibly doing wrong?

psylenced 07-28-2008 07:37 AM

Can this mod read the message ID directly out of the email source?

If it can wouldn't it be easier to read this rather than creating an individual email address for each user or email sent.


Quote:

Originally Posted by scsa20 (Post 1585745)
I'm trying to set this up and when I test the connection to the pop server, I get the following error message:

110 could not connect to the host "pop.gmail.com": Connection timed out

what am I possibly doing wrong?

Have you enabled pop in your settings on gmail? Also if you read their help it might give you a different address - maybe you've typed it wrong..

scsa20 07-28-2008 09:19 PM

no, the pop is turned on, and it's the correct address it told me to use, and set the port to 995, still gives me the error.


All times are GMT. The time now is 01:34 PM.

Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.

X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.01638 seconds
  • Memory Usage 1,927KB
  • Queries Executed 10 (?)
More Information
Template Usage:
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (5)bbcode_code_printable
  • (16)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (3)pagenav_pagelink
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (40)printthreadbit
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • showthread
Included Files:
  • ./printthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/class_bbcode_alt.php
  • ./includes/class_bbcode.php
  • ./includes/functions_bigthree.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • printthread_start
  • pagenav_page
  • pagenav_complete
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete