Resource icon

Remove notice "This message is awaiting moderator approval, and is invisible to normal visitors."

MaximilianKohler

Active member
MaximilianKohler submitted a new resource:

Remove notice "This message is awaiting moderator approval, and is invisible to normal visitors." - Remove waiting for moderator approval notice

F12 to open developer console of your browser. Click the "element picker" on left side. Click on the notice.

Here's the default CSS code:
Code:
<div class="messageNotice messageNotice--moderated">
  ::before
  This message is awaiting moderator approval, and is invisible to normal visitors.
</div>


.messageNotice {
  margin: 6px 0;
  padding: 6px 10px;
  color: #aa6709;
  background: #fff4e5;
  font-size: 12px;
  border-left: 2px solid #ba8132;
}

Edit the extra.less file of each...

Read more about this resource...
 
For macOS users:

In your Safari menu bar click Safari > Preferences & then select the Advanced tab.

Select: "Show Develop menu in menu bar"
Now you can click Develop in your menu bar and choose Show Web Inspector

See a detailed guide here for more info: LINK

You can also right-click and press "Inspect element".
 
I don't understand this "resource" when this is much easier accomplished thusly:
Thanks Max! I'm actually a total newbie and couldn't find such a tip when I searched, so that's why I posted this. I wasn't sure where to post it either.

I just tested your code and it seems to do the same thing. Both of them are actually problematic in the same way -- they remove the info/links on the mod queue as well:
approval-queue-jpg.288178

approval-queue-2-jpg.288179


Does anyone know of a better solution?
 
Actually modify the template that you will normally see this from... think it (for general forum posts) would be the post_macrostemplate.

Around line 194
Code:
<xf:elseif is="$post.message_state == 'moderated'" />
        <div class="messageNotice messageNotice--moderated">
            {{ phrase('this_message_is_awaiting_moderator_approval_and_is_invisible_to_normal') }}
        </div>
    </xf:if>

try something like
Code:
<xf:elseif is="$post.message_state == 'moderated'" />
        <div class="messageNotice messageNotice--moderated">
<xf:if is="{{$xf.visitor.isMemberOf([ 3, 4])}}>
 {{ phrase('this_message_is_awaiting_moderator_approval_and_is_invisible_to_normal') }}
        </div>
    </xf:if>
</xf:if>

That should (have not tested) only display it to anyone in the Adminstrators group or Moderating group.
You could probably create a template mod to apply automatically and not have to worry about merging templates when updating.
 
Last edited:
Actually modify the template that you will normally see this from... think it (for general forum posts) would be the post_macrostemplate.

That should (have not tested) only display it to anyone in the Adminstrators group or Moderating group.
You could probably create a template mod to apply automatically and not have to worry about merging templates when updating.
Perfect, thank you!!

I just had to modify it a bit like this:
<xf:elseif is="$post.message_state == 'moderated'" />
<xf:if is="{{$xf.visitor.isMemberOf([ 3, 4])}}">
<div class="messageNotice messageNotice--moderated">
{{ phrase('this_message_is_awaiting_moderator_approval_and_is_invisible_to_normal') }}
</div>
</xf:if>
</xf:if>
 
Yep... left out the <> on the member group level... making that post from my phone while outside with the telescope. Didn't take my Surface Book out with me as I'm trying out the IOS app for the control software.
Just one more reason why phones don't work real well for "detail oriented use" with stuff like this!
 
Thanks Max! I'm actually a total newbie and couldn't find such a tip when I searched, so that's why I posted this. I wasn't sure where to post it either.

I just tested your code and it seems to do the same thing. Both of them are actually problematic in the same way -- they remove the info/links on the mod queue as well:
approval-queue-jpg.288178

approval-queue-2-jpg.288179


Does anyone know of a better solution?
That's odd I've never had that happen.
 
Actually modify the template that you will normally see this from... think it (for general forum posts) would be the post_macrostemplate.

try something like
Code:
<xf:if is="{{$xf.visitor.isMemberOf([ 3, 4])}}>

</xf:if>
That should (have not tested) only display it to anyone in the Adminstrators group or Moderating group.
This was super useful and I've been applying it to more things. I'm wondering what the specific parts of the code mean and if there's a place where we can learn about things like this? IE: I'm not sure what isMemberOf([ 3, 4] means.
 
Top Bottom