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

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

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:
UBS downgrades the U.S. stock market. Here's what has the investment bank worried
Trump Media in talks to spin off Truth Social from DJT into independent stock
Target to remove synthetic color from cereals by May end
Core wholesale prices rose 0.8% in January, much more than expected
UBS turns bullish on Palantir, says buy the dip on this clear AI winner
Answered: Can I upload video in q2a by a plugin?
The digital front: Iran’s internet down for over 60 hours amid reports of cyberattacks
The Strait of Hormuz crisis explained: What it means for global shipping
Movie: EPiC: Elvis Presley in Concert
Monarch: Legacy of Monsters: Cause and Effect