Answered: How to prevent users level registered to sending private messages in a q2a forum?

Post date: 2024-02-07 07:22:01
Views: 160

in qa-include/pages/message.php 

change  this at line 150

if ($toaccount'flags'] & QA_USER_FLAGS_NO_MESSAGES) {

to this

if (($toaccount'flags'] & QA_USER_FLAGS_NO_MESSAGES) && qa_get_logged_in_level() < QA_USER_LEVEL_SUPER) {

and

in qa-include/pages/user-profile.php  

change this at line 791

if (qa_opt('allow_private_messages') && isset($loginuserid) && $loginuserid != $userid && !($useraccount'flags'] & QA_USER_FLAGS_NO_MESSAGES) && !$userediting) {

to this

if ((qa_opt('allow_private_messages') && isset($loginuserid) && $loginuserid != $userid && !($useraccount'flags'] & QA_USER_FLAGS_NO_MESSAGES) && !$userediting) || qa_get_logged_in_level() >= QA_USER_LEVEL_SUPER) {

Please click Here to read the full story.
 
Other Top and Latest Questions:
2 confidence-building tools for parents to set kids up for 'a lifetime of success,' from a mental performance coach
Robinhood's venture fund, which gives investors access to private companies, tanks 11% on first day
Iran's internet blackout extends into second week: NetBlocks
Organizations that track public comment opportunities for fed policies?
How many points are required to edit the user profile?
Star Trek: Starfleet Academy: 300th Night
Stargate SG-1: The Light Rewatch
Book: Elantris
Trump urges Latin American leaders to use military to help the U.S. fight cartels
Jan. 6 plaque honoring police officers quietly installed at the Capitol after a 3-year delay