Fixed : Users getting duplicate mails.
View Team Webgalli's plugins
info@elgg.org
Security issues should be reported to security@elgg.org!
©2014 the Elgg Foundation
Elgg is a registered trademark of Thematic Networks.
Cover image by Raül Utrera is used under Creative Commons license.
Icons by Flaticon and FontAwesome.
Thanks for this great plugin!
I am using it with the "User validation by admin" plugin, and it seems that there is some trouble putting both plugins together. Mass mailout does not check if an user has been validated or not, and hence it sends mass emails even to unvalidated users. Looking at the Mass mailout plugin code, it seems that it doesn't check wheter a user has been banned, but I have not tested this case. Perhaps I am missing something.
I have modified the SQL query in galliMassmail_select_emails() function to consider banned and unvalidated users, just in case it were useful for anyone.
function galliMassmail_select_emails($limit = 10, $offset =0){
$dbPrefix = elgg_get_config('dbprefix');
$query = "SELECT email from {$dbPrefix}users_entity WHERE banned='no' AND last_login > 0 ORDER BY {$dbPrefix}users_entity.guid ASC LIMIT $offset, $limit";
return get_data($query);
}
@David : Yes, it wont send mail to all registered emails in the system irrespective of their validation status. The modification, you shown should work. You can submit it as a pull request for the plugin through github.
First time using and its not sending out emails says "incomplete" ????
another useful enhancement would be to give the option of sending the messages to the elgg internal inbox too.. maybe an option to send to email, to internal inbox or to both.