Posted by AndrewC on October 31, 2006 at 3:51pm
8 followers
| Project: | Notify |
| Version: | 5.x-1.x-dev |
| Component: | User interface |
| Category: | feature request |
| Priority: | normal |
| Assigned: | Unassigned |
| Status: | reviewed & tested by the community |
Issue Summary
It would be great to be able to have logintoboggan set the notify default for users. As admin, it would be very helpful to be able to turn this on by default for new users, and if they don't like it, they can go in later and turn it off.
For my uses, most people want this on, but it is very difficult to get them to go in and turn it on for themselves.
Comments
#1
i'm afraid i don't know what you're referring to. can you be more specific?
#2
I'll take a wild guess that he's referring to the Notify module. At least it's a feature I want for that module. It doesn't feel right to implement it in Logintoboggan. I'd expect that to be a setting in Notify (so that it would be available with or without Logintoboggan).
#3
#4
Oops, slippery mouse.
#5
The notify module allows users to receive email when new nodes/content has been added to the site.
The problem I find is that very few users ever turn on this very useful feature. For my sites, I would like to be able to have it turned on by default for ALL users.
If it annoys them, it is easy enough to turn off on an individual user basis.
As one person noted, it would actually be best if the site admin can set this in the notify settings.
#6
this doesn't seem like a logintoboggan feature request. recategorizing.
#7
This would be a great feature. I have hacked my current copy of notify.module to do just this. It was as easy as updating notify_user to the following:
<?phpfunction notify_user($type, &$edit, &$user, $category = NULL) {
switch ($type) {
case 'insert':
db_query('INSERT INTO {notify} VALUES(%d,1,1,1,0,0)', $user->uid);
break;
case 'delete':
db_query('DELETE FROM {notify} WHERE uid = %d', $user->uid);
break;
}
}
?>
I have hard coded the values of the different options but breaking this out to an administrative form should be pretty darn simple. If I get the time I may do this and provide the code.
#8
Hi there,
This is a great idea, and would make Notify much more useful to non-technical users, who, on my site, don't know how to set this up, or are not aware it exists.
I'll try the hard coding, but would feel much safer if it was included in the module itself, with an admin toggle.
#9
Okay, here is a patch to the latest stable release (5.x-1-1) that should provide admin options to allow for default user notify settings. I have not tested at all yet (should be able to tomorrow), so use at your own risk.
#10
I have not tested the patch.
Just a small review on the code style:
* don't use tabs, but 2 spaces.
* put the '#type' => 'radios', on their own line, aligned with the other array elements.
Note: I will not review this patch further, nor consider it for inclusion until the second list of issues (bugs) is properly dealt with:
http://drupal.org/node/159427
#11
Ok, I fixed the formatting issues (FYI...I had simply copied and pasted the code from elsewhere in the same file) and tested it and it seems to work just great!
#12
will this work if you don't use logintobbaggan?
#13
I would like to have an option I can set to turn notification on by default. Could this be included when upgrades are done for version 6? I looked at the patch but I don't know php or MySQL and I'm hesitant to start applying patches.
#14
Applied the patch on #9 against 5.x-1.x-dev and it is working fine for about two months in my live site. It's a nice feature addition that should get in to the module.
Answering #12: the patch works independently of logintoboggan.