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

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

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:
[New Premium Theme] Qlassy Theme with complete features - Beta Version
Lilly trial shows weight loss with experimental pill flattens over time
Activist investor Elliott takes more than $2 billion stake in Workday, backs leadership
Eli Lilly aims to bring more manufacturing home — plus, the good and bad among our industrials
Wednesday's big stock stories: What’s likely to move the market in the next trading session
China's Baidu soars 16% to hit 2-year highs amid positive signs for its AI business
Microsoft, Nvidia, other tech giants plan over $40 billion of new AI investments in UK
Fed set to cut rates, but forecast for rest of 2025 is key to markets with politics clouding the picture
LimeWire acquires Fyre Festival, asking 'What Could Possibly Go Wrong?'
Oracle and Silver Lake part of TikTok investor group as Trump extends deal deadline