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

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

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:
Investors may want to focus on front end of yield curve — as Street anticipates next Fed meetings
From a Fed decision to Big Tech earnings: What drove last week's volatile market
The best 5-year CD rates of August 2026: Up to 4.35%
How to find the bus/shuttle from Rockaway Beach BACK to the ferry?
Managing anxiety post-surgery when you can't take a deep breath?
X-Men '97: Strange Land, Savage Heart
Star Trek: Strange New Worlds: The Griffin Incident
Movie: Hadestown: The Musical
Movie: An Elephant Sitting Still
Buying a condo with a mortgage may soon get more complicated. Here's why