Mod to set user defaults for advanced email notification options

Started by beebauman, November 29, 2011, 03:17:26 PM

Previous topic - Next topic

beebauman

Hi, I am running SMF 2.0.1. I want to be able to configure the defaults for the following 3 settings for all current and future new users:

1. "When sending notification of a reply to a topic, send the post in the email"
2. "For topics and boards I've requested notification on, notify me:..."
3. "For topics and boards I've requested notification on, notify me of:"

Right now I am able to set these manually on a per-user basis in the Modify Profile - Notifications area of an individual user's profile.

There is another related setting "Turn notification on when you post or reply to a topic" which I *am* able to control the default for with existing and future new users in: Admin - Themes and Layout Settings - Member Options - Configure guest and new user options for this theme/Change current options for all members using this theme".

However I want to control the other 3 options in this way as well. How can I create a mod that will enable me to do so? Thank you very much in advance!


davegior

I'm looking for the same mod. Be nice if it was added in the next version update.


Wilo

Me too, I'm also looking for a mod which turns on notifications for member groups.

emanuele

Code not tested!!

Open Subs-Members.php (in Sources):
Code (find) Select
'pm_email_notify' => 1,
Code (add after) Select
'notify_send_body' => 1,
'notify_regularity' => {regularity_you_want},
'notify_types' => {type_you_want},


Then replace {regularity_you_want} with the number of the one you want from:
* 0 => Instantly
* 1 => Instantly - but only for the first unread reply
* 2 => Daily
* 3 => Weekly

and {type_you_want} with the number of the type you want from:
* 1 => Replies and moderation
* 2 => Moderation only if I started the topic
* 3 => Only replies
* 4 => Nothing at all

That will apply for all new members.


Take a peek at what I'm doing! ;D




Hai bisogno di supporto in Italiano?

Aiutateci ad aiutarvi: spiegate bene il vostro problema: no, "non funziona" non è una spiegazione!!
1) Cosa fai,
2) cosa ti aspetti,
3) cosa ottieni.

davegior

Quote from: emanuele on February 21, 2012, 11:14:41 AM
Code not tested!!

Open Subs-Members.php (in Sources):
Code (find) Select
'pm_email_notify' => 1,
Code (add after) Select
'notify_send_body' => 1,
'notify_regularity' => {regularity_you_want},
'notify_types' => {type_you_want},


Then replace {regularity_you_want} with the number of the one you want from:
* 0 => Instantly
* 1 => Instantly - but only for the first unread reply
* 2 => Daily
* 3 => Weekly

and {type_you_want} with the number of the type you want from:
* 1 => Replies and moderation
* 2 => Moderation only if I started the topic
* 3 => Only replies
* 4 => Nothing at all

That will apply for all new members.

Thanks emanuele, works great

emmjaibi

Just so I understand - this only works for new users and not existing, right?

I would love to be able to modify notification settings for ALL users as I find some users have notification set for 'first reply only' and then they never seem to get notifications later for new topics on monitored boards because they hadn't logged in since that first notification.

If there was some way to ensure users got notified of new TOPICS all the time even if they've not been online since other topics or replies were added, that would be ideal.

But the way it seems to work now is like so:
1) Topic A is posted and User X reads it then logs out.
2) Later User Y posts a reply to Topic A and User X gets a notification email.
3) Some time later (hours/days) Topic B is posted by some user (other than User X) but because User X hasn't logged in since that reply to Topic A was posted (item 2 above), they never get a notification for Topic B.

This is how it works, right?

Advertisement: