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

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

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:
U.S. sanctions companies and individuals in the Middle East and China for helping Iran
Iran focus at Trump-Xi summit may delay progress on tariffs, rare earths
Putin says he thinks Russia-Ukraine war is coming to an end
How to take control of the AI data center boom and built it into your own home in the future
Should I get an adult tricycle?
I have more computing power on my desk than 1962 America
Answered: Looks like QA is not supported anymore?
Book: Platform Decay
Retailers are on a hiring spree. But consumers are sending warning signs
Used car prices fall for the first time this year and EV interest rises as gas prices spike