I want to remove this text that appears in a moderated post for one user only along with the red background color.
Note: This message is awaiting approval by a moderator.
Basically I do not want that member to know that his posts are being moderated.
Is it something like if user_info['id'] = 4? At what template? Please help me with this because it is very important to me.
And I do know that it is kind of pointless, but the user in question is not tech savvy and will not catch on. He is getting very irritating but I do not want to ban him outright as he is a long member of my forum.
In themes display.template.php
if (!$message['approved'] && $message['member']['id'] != 0 && $message['member']['id'] == $context['user']['id'])
echo '
<div class="approve_post">
', $txt['post_awaiting_approval'], '
</div>';
Thanks mate. I do not see any condition for user_id 4 in that code. Checking the display.template.php file I see that that is the original code. How can I add the condition in there?
CHANGE TO
if (!$message['approved'] && $message['member']['id'] != 0 && $message['member']['id'] == $context['user']['id'] && $message['member']['id'] != 4))
That is giving me an error.
change to
if (!$message['approved'] && $message['member']['id'] != 0 && $message['member']['id'] == $context['user']['id'] && $message['member']['id'] != 4)
It is not working for me. I have an user at my forum who knows little php and he created a script that adds a new column in the members table called is_ignored. How can I add that to the conditional? I tried this but it did not work
if (!$message['approved'] && $message['member']['id'] != 0 && $message['member']['id'] == $context['user']['id'] && $message['member']['id'] != $context['user']['is_ignored'])
Just a quick note, pretty much never is it really a good idea to call out any specific member with a general support issue. It will work against you.
This includes but is not limited to mentioning a username in a title like in this case, and/or sending a pm/email/IM/smoke signals.
Give this a try.
if (!$message['approved'] && $message['member']['id'] != 0 && $message['member']['id'] == $context['user']['id'] && !$message['member']['is_ignored'])
It is untested, but it should work.
Quote from: Aleksi "Lex" Kilpinen on March 31, 2019, 07:22:52 AM
Just a quick note, pretty much never is it really a good idea to call out any specific member with a general support issue. It will work against you.
This includes but is not limited to mentioning a username in a title like in this case, and/or sending a pm/email/IM/smoke signals.
Why was it a bad idea? I meant it well. But from now on I will not call out any specific member.
Doug_ips thans mate. I will try it and let you know if it will work.
Because everyone here volunteers their time, including the team, and it can seem demanding, even if not meant that way.
Quote from: Aleksi " Lex " Kilpinen on April 01, 2019, 09:43:30 AM
Because all the peoples here volunteers their time, including the team, and it can seem demanding, even if not meant that way.
I see. Well, I will not be doing it anymore in that case.
Doug_ips your code worked only partly. It removed the text that appears in a moderated post but it did not remove the pinkish background color. Please someone help.
Thank you for understanding.