How to Stop Email Notifications for Non-active Members

Get help with installation and running phpBB 3.2.x here. Please do not post bug reports, feature requests, or extension related questions here.
User avatar
gpraceman
Registered User
Posts: 38
Joined: Sun Jul 06, 2003 12:21 am
Location: Highlands Ranch, CO
Contact:

How to Stop Email Notifications for Non-active Members

Post by gpraceman »

Is there a way to disable auto notifications for members that have not been active in the board for quite a stretch (like a year or more)?

My forum has been around since 2003, so I have a lot of members that have not been active for a long time. I have a feeling that when these members get updated thread notices, that they may be flagging them as spam, instead of using the link in the email notice to unsubscribe from the notification. Enough people do that, and we get emails from our server blocked by ISPs like Yahoo, Hotmail, MSN, Gmail, etc. It is a pain to get our server unblocked. It is a dedicated server that hosts a few of my sites. I am currently running phpBB 3.2.7
Awana Grand Prix and Pinewood Derby racing - The most fun you can have with a block of wood.
KYPREO
Registered User
Posts: 392
Joined: Fri Feb 02, 2018 9:56 am
Contact:

Re: How to Stop Email Notifications for Non-active Members

Post by KYPREO »

I recently brought up the same issue and suggested an extension to deal with it: viewtopic.php?f=496&t=2540906

There is no option in the ACP to individually override a user's notification preferences. Unfortunately, there is apparently no way for an extension to prevent notification emails being sent to specific users.

An extension could allow an admin to gain access to individual user's notification settings and de-select notify by email.

The alternative is to manually change user notification settings in the forum database by executing mySQL queries. I am reluctant to recommend that approach unless you are comfortable with mySQL as things can go wrong if you get database queries wrong.

Meanwhile, if emails are being marked as spam, you should check the following:
- do you have a valid MX record for your mail (check here: https://mxtoolbox.com/MXLookup.aspx)
- does a reverse DNS check for your mail server IP correspond with your mail server hostname (check here: https://mxtoolbox.com/ReverseLookup.aspx)
- is your IP on a blacklist (check here: https://mxtoolbox.com/blacklists.aspx)
- do you have valid SPF/DKIM and/or DMARC set up? (use the SuperTool here: https://mxtoolbox.com/SuperTool.aspx)
- is your mail server being used as an open relay for spammers? (check here: https://mxtoolbox.com/diagnostic.aspx)
- does your mail server IP have a poor reputation on one of the established reputation databases used by mail servers to filter spam (eg https://senderscore.org/, https://talosintelligence.com/reputation_center
- send an email using the Mail Tester tool and consider the recommendations: https://www.mail-tester.com/
phpBB user since 2002
www.AusRotary.com
User avatar
72degrees
Registered User
Posts: 67
Joined: Wed Jan 29, 2020 12:43 pm
Location: UK
Contact:

Re: How to Stop Email Notifications for Non-active Members

Post by 72degrees »

KYPREO wrote:
Wed Feb 19, 2020 6:43 am

Meanwhile, if emails are being marked as spam, you should check the following:
Many, many thanks for that. I am currently investigating a mail shot of 5000 emails with PDF attachments (of AGM notices) where a significant number (approx 100) did not reach the recipients inbox although the email used was certainly correct (few bounces). Not even marked as spam but 'dropped'. I have considered some of your points but can find no obvious pattern in the email account or ISP of the failed messages. The strategy next time will be to send just a notification mail with instructions how to retrieve the PDFs from a website (no URL or mailto: links at all).

OT for here I suspect, but I'm glad to see I have been checking the right things.
'And what is good, Phaedrus, And what is not good—Need we ask anyone to tell us these things?'
User avatar
Brf
Support Team Member
Support Team Member
Posts: 52305
Joined: Tue May 10, 2005 7:47 pm
Location: {postrow.POSTER_FROM}
Contact:

Re: How to Stop Email Notifications for Non-active Members

Post by Brf »

gpraceman wrote:
Tue Feb 18, 2020 8:23 pm
updated thread notices,

I assume you mean a Topic Reply notice.
The way notifications were designed to work is, If the user does not visit the topic, they do not receive any more notifications for it.

I am not sure that is true anymore for Forum-new-Topic notifications, but I thought the Reply notifications still worked like that.
User avatar
gpraceman
Registered User
Posts: 38
Joined: Sun Jul 06, 2003 12:21 am
Location: Highlands Ranch, CO
Contact:

Re: How to Stop Email Notifications for Non-active Members

Post by gpraceman »

KYPREO wrote:
Wed Feb 19, 2020 6:43 am
I recently brought up the same issue and suggested an extension to deal with it: viewtopic.php?f=496&t=2540906

There is no option in the ACP to individually override a user's notification preferences. Unfortunately, there is apparently no way for an extension to prevent notification emails being sent to specific users.

An extension could allow an admin to gain access to individual user's notification settings and de-select notify by email.

The alternative is to manually change user notification settings in the forum database by executing mySQL queries. I am reluctant to recommend that approach unless you are comfortable with mySQL as things can go wrong if you get database queries wrong.
I was hoping there was some way currently or with an extension. I have no problem running SQL queries, if that is my only option.
KYPREO wrote:
Wed Feb 19, 2020 6:43 am
Meanwhile, if emails are being marked as spam, you should check the following:
- do you have a valid MX record for your mail (check here: https://mxtoolbox.com/MXLookup.aspx)
- does a reverse DNS check for your mail server IP correspond with your mail server hostname (check here: https://mxtoolbox.com/ReverseLookup.aspx)
- is your IP on a blacklist (check here: https://mxtoolbox.com/blacklists.aspx)
- do you have valid SPF/DKIM and/or DMARC set up? (use the SuperTool here: https://mxtoolbox.com/SuperTool.aspx)
- is your mail server being used as an open relay for spammers? (check here: https://mxtoolbox.com/diagnostic.aspx)
- does your mail server IP have a poor reputation on one of the established reputation databases used by mail servers to filter spam (eg https://senderscore.org/, https://talosintelligence.com/reputation_center
- send an email using the Mail Tester tool and consider the recommendations: https://www.mail-tester.com/
I've been chasing this problem for years. Yes, I have MX, SPF, DKIM, DMARC, and reverse DNS all setup. I'll check out those other links.
Awana Grand Prix and Pinewood Derby racing - The most fun you can have with a block of wood.
User avatar
stevemaury
Support Team Member
Support Team Member
Posts: 51905
Joined: Thu Nov 02, 2006 12:21 am
Location: The U.P.
Name: Steve
Contact:

Re: How to Stop Email Notifications for Non-active Members

Post by stevemaury »

Stop chasing. If they get one notice but do not visit the topic (not thread) they will get no more. Solved.
For REALLY good and VERY inexpensive hosting CLICK HERE

I can stop all your spam. I can upgrade or update your Board. PM or email me. (Paid support)
KYPREO
Registered User
Posts: 392
Joined: Fri Feb 02, 2018 9:56 am
Contact:

Re: How to Stop Email Notifications for Non-active Members

Post by KYPREO »

stevemaury wrote:
Thu Feb 20, 2020 10:01 pm
Stop chasing. If they get one notice but do not visit the topic (not thread) they will get no more. Solved.
Nope.

Not if they've chosen to receive notifications by email only - they'll continue to get notifications for every reply. This will often happen on old boards because the notification feature was introduced after users had already subscribed to topics. This is a known bug unresolved for 3.5 years: https://tracker.phpbb.com/browse/PHPBB3-14754 and https://github.com/phpbb/phpbb/pull/5337

They'll also continue to get email notifications if they've subscribed to a forum. They get a notification for every new topic or reply to a topic since their last visit.

They'll also get them for every PM.

I have many many old users who subscribed to dozens of topics and multiple fora. They get an email every single time.

As I mentioned above, there is no way for an admin to change a user's notification preferences. Furthermore, in vanilla phpBB, there is no way for an admin to unsubscribe users to specific topics or fora.

So this is a real problem with apparently no solution without dabbling with the database at the back end. I have had 242 bounceback emails in the past week, so stop chasing is not really a solution.
phpBB user since 2002
www.AusRotary.com
User avatar
Brf
Support Team Member
Support Team Member
Posts: 52305
Joined: Tue May 10, 2005 7:47 pm
Location: {postrow.POSTER_FROM}
Contact:

Re: How to Stop Email Notifications for Non-active Members

Post by Brf »

Have you tried manually deleting records from the forums_watch and topics_watch tables for those users?
User avatar
gpraceman
Registered User
Posts: 38
Joined: Sun Jul 06, 2003 12:21 am
Location: Highlands Ranch, CO
Contact:

Re: How to Stop Email Notifications for Non-active Members

Post by gpraceman »

Brf wrote:
Fri Feb 21, 2020 4:28 pm
Have you tried manually deleting records from the forums_watch and topics_watch tables for those users?
Sounds pretty tedious. I've got hundreds of members that this issue affects.

There needs to be a simple button or link for the admin interface to click to remove notifications from members that have not been active for X amount of time or longer. Better yet, an automated process that the admin doesn't need to manually trigger. Turn the feature on and set the inactive time threshold. Then let it do its thing.
Awana Grand Prix and Pinewood Derby racing - The most fun you can have with a block of wood.
KYPREO
Registered User
Posts: 392
Joined: Fri Feb 02, 2018 9:56 am
Contact:

Re: How to Stop Email Notifications for Non-active Members

Post by KYPREO »

Brf wrote:
Fri Feb 21, 2020 4:28 pm
Have you tried manually deleting records from the forums_watch and topics_watch tables for those users?
I think the quicker way is probably to modify the user's user notification options to deselect "Email". This way they stay subscribed and don't lose their last visited stats for those susbscriptions and therefore keep any board notifications. But they won't continue to be sent email notifications.

These options are stored in the _user_notifications table in the method column. You can see a user's notification options running the query:

Code: Select all

SELECT * FROM phpbb_user_notifications WHERE user_id LIKE '####'
Change any email methods specified for that user from 1 to 0.

I only had a quick look this morning so i don't want to post the query to change these settings until I've fully tested.

I think it would be polite to PM a user to say their email notifications have been disabled until they provide a working email address. They should then get a notification of the PM when (if) they next log in.

I think an extension that adds a page in the ACP User Administration module to change user notification options would be fantastic. I have never written an extension so i might even have a go myself.
phpBB user since 2002
www.AusRotary.com
KYPREO
Registered User
Posts: 392
Joined: Fri Feb 02, 2018 9:56 am
Contact:

Re: How to Stop Email Notifications for Non-active Members

Post by KYPREO »

OK so here's one way of stopping email notifications for all known dead email addresses in one go.

Start making a list of email addresses in any bounceback messages you get.

Run the following query to identify affected user numbers (replace addresses with your list, contained in inverted commas and separated by commas):

Code: Select all

SELECT user_id FROM phpbb_users WHERE user_email IN('address1@email.com','address2@email.com');
Save/copy the user_ids as a comma separated list and run the following query to turn off email notifications for those users:

Code: Select all

UPDATE phpbb_user_notifications SET notify = 0 WHERE method = 'notification.method.email' AND user_id IN(1,2,3);
where 1,2,3 etc are the user_id of the users for whom you want email notifications turned off.

I'm sure you can combine these 2 queries into one to make life easier. But I left it like this for now. If your list of email addresses is long enough, you could put them in a CSV or TXT file and run the query from that.

I also think that being able to edit user notification options should be part of the core functions of the ACP rather than an extension. You can edit every single other user preference except this one. There's no real justification for that. I recall reading old posts saying it wouldn't right for an admin to change a user's notification options, but this really makes no sense when you can change their username, contact details, avatar, signature, password, display options, posting defaults etc, etc It simply looks like when user_notification option page was introduced (I think in phpBB 3.2?) the corresponding ACP module was not updated. Adding this feature looks easy enough and I might have a go at this myself.
phpBB user since 2002
www.AusRotary.com
User avatar
3Di
Former Team Member
Posts: 16174
Joined: Mon Apr 04, 2005 11:09 pm
Location: Milano 🇮🇹 Frankfurt 🇩🇪
Name: Marco
Contact:

Re: How to Stop Email Notifications for Non-active Members

Post by 3Di »

KYPREO wrote:
Sun Feb 23, 2020 12:46 am
I also think that being able to edit user notification options should be part of the core functions of the ACP rather than an extension.
:shock:
But it also doesn't! It would be contrary to every law regarding the freedom of will and personal choices of anyone.
I don't know if privacy and personal freedom is just optional?
🆓 Free support for our extensions also provided here: phpBB Studio
🚀 Looking for a specific feature or alternative option? We will rock you!
Please PM me only to request paid works. Thx. Want to compensate me for my interest? Donate
My development's activity º PhpStorm's proud user º Extensions, Scripts, MOD porting, Update/Upgrades
User avatar
3Di
Former Team Member
Posts: 16174
Joined: Mon Apr 04, 2005 11:09 pm
Location: Milano 🇮🇹 Frankfurt 🇩🇪
Name: Marco
Contact:

Re: How to Stop Email Notifications for Non-active Members

Post by 3Di »

KYPREO wrote:
Sun Feb 23, 2020 12:46 am
Adding this feature looks easy enough and I might have a go at this myself.
For me and many others too, but I'm pretty sure you'll find it very difficult to get it merged eventually. :P
🆓 Free support for our extensions also provided here: phpBB Studio
🚀 Looking for a specific feature or alternative option? We will rock you!
Please PM me only to request paid works. Thx. Want to compensate me for my interest? Donate
My development's activity º PhpStorm's proud user º Extensions, Scripts, MOD porting, Update/Upgrades
KYPREO
Registered User
Posts: 392
Joined: Fri Feb 02, 2018 9:56 am
Contact:

Re: How to Stop Email Notifications for Non-active Members

Post by KYPREO »

3Di wrote:
Sun Feb 23, 2020 12:56 am
KYPREO wrote:
Sun Feb 23, 2020 12:46 am
I also think that being able to edit user notification options should be part of the core functions of the ACP rather than an extension.
:shock:
But it also doesn't! It would be contrary to every law regarding the freedom of will and personal choices of anyone.
I don't know if privacy and personal freedom is just optional?
I understand those arguments, but you can just turn them on via the database anyway. Ultimately the conduct of the administrators are what will render an action in breach or not.

In any event, as it stands, the ACP already allows me change a user's preference for:
* Users can contact me by email:
* Administrators can email me information:
* Notification method: Method for sending messages sent via this board.
* Notify me on new private messages:

(ACP > Users & Group > User Administration > Preferences > Edit global settings)

All of these options affect whether users receive email notifications and I can change them all from OFF to ON. What's the difference being able to turn individual types of notifications on/off? Nothing.

Also, we're only talking about turning notifications OFF here - effectively unsubscribing them from email notifications, which is the opposite of spam :P ...and they're not getting the emails anyway, because they don't have a valid email address. Every admin should be able to have control of where notification emails are being sent by their board. This is in fact within the spirit of anti-spam legislation. You will find many privacy/anti-spam laws and codes require those who manage mailing lists to keep the list clean by removing dead emails. This is why some IP reputation services actually mark you down for repeatedly sending emails to dead addresses. I could equally argue phpBB is currently in default of those requirements because it does allow an admin to prevent the board from sending emails to dead addresses.

Even assuming someone did want to manually subscribe users to email notifications (not what I'm advocating), this is not necessarily contrary to law. It depends on the jurisdiction and the terms of use the user signed up to. ;)
phpBB user since 2002
www.AusRotary.com
User avatar
3Di
Former Team Member
Posts: 16174
Joined: Mon Apr 04, 2005 11:09 pm
Location: Milano 🇮🇹 Frankfurt 🇩🇪
Name: Marco
Contact:

Re: How to Stop Email Notifications for Non-active Members

Post by 3Di »

KYPREO wrote:
Sun Feb 23, 2020 1:31 am
I understand those arguments, but you can just turn them on via the database anyway.
That's the way to go in case and at the present time.
KYPREO wrote:
Sun Feb 23, 2020 1:31 am
In any event, as it stands, the ACP already allows me change a user's preference for:
....
Reiterating then some points already expressed in your previous post is certainly not helpful to the discussion, to these I have already answered concisely and without a shadow of a doubt.
KYPREO wrote:
Sun Feb 23, 2020 1:31 am
I could equally argue phpBB is currently in default of those requirements because it does allow an admin to prevent the board from sending emails to dead addresses.
I think you meant "it does NOT allow"?...
So surely you should find another system to prevent this one that obviously is not what you have in mind to propose and that will never be accepted, at least from my point of view.
KYPREO wrote:
Sun Feb 23, 2020 1:31 am
Even assuming someone did want to manually subscribe users to email notifications (not what I'm advocating), this is not necessarily contrary to law. It depends on the jurisdiction and the terms of use the user signed up to.
The software can't meet all the needs of every country in the world, if it's okay for you for another not, as for the GDPR, in fact there are extensions to overcome these drawbacks. You could take one for example and create one that meets your criteria and those of the country where you live, another illustration.
🆓 Free support for our extensions also provided here: phpBB Studio
🚀 Looking for a specific feature or alternative option? We will rock you!
Please PM me only to request paid works. Thx. Want to compensate me for my interest? Donate
My development's activity º PhpStorm's proud user º Extensions, Scripts, MOD porting, Update/Upgrades
Post Reply

Return to “[3.2.x] Support Forum”