Gossamer Forum
Home : Products : Gossamer Forum : Discussion :

Admin should be able to private message any user

Quote Reply
Admin should be able to private message any user
When a user turns off "Allow private messages" why is the Admin not able to private message him?
I would think the Admin would be able to overwrite his preference in order to privately contact him, escpecially if the user is causing trouble.

Is there a workaround to allow the admin to send the private message to the user with messages turned off?

Thanks

----------
Michael J. Challis - CRUZN8R - PT Cruiser Club - http://www.ptcruiserclub.org

http://www.ptcruiserclub.org/forum
Post deleted by SeanP In reply to
Quote Reply
Re: [CRUZN8R] Admin should be able to private message any user In reply to
A code hack in GForum/Message.pm would be to change the following on line 745:

Code:
$recipient->{user_accept_privmsg} and $recipient->{user_enabled}
or return(
$page->{no_privmsg} => {
error => GForum::language('USER_NO_PRIVMSG', $recipient->{user_username})
}
);

...to....

Code:
(($recipient->{user_accept_privmsg} or $USER->{user_status} == ADMINISTRATOR) and $recipient->{user_enabled})
or return(
$page->{no_privmsg} => {
error => GForum::language('USER_NO_PRIVMSG', $recipient->{user_username})
}
);

There are better ways of doing this but it's just a quick hack. Bear in mind that you'll lose the change when you do an upgrade.