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

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

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:
Trump administration equity stakes pose risks to U.S. companies and markets
Trump condemns racist video showing Obamas as apes after removing it, but says he won't apologize
Couple bought a 140-year-old New Jersey home for $550,000 and spent $172,000 renovating it—take a look inside
Berkshire Hathaway outperforms this week as tech stocks sink
Pressure mounts on American Airlines CEO as carrier lags rivals
Top Wall Street analysts like these stocks for long-term growth potential
NFL plans to have discussions with partners outside of core media for live games, media chief says
Tech giants in China sold off alongside their U.S. peers last week. How to play it
Japanese Prime Minister Takaichi's ruling LDP set to secure supermajority in Lower House: NHK
Federal judge orders Fulton County Georgia election case documents unsealed by Tuesday