• REGISTRATION REQUIREMENTS:

    Your username here MUST MATCH your XenForo username (connected to your XF license).

    Once you have registered here, then you need to start a conversation at xenforo.com w/Bob and provide the following:
    1. Your XenForo License Validation Token
    2. The Domain Name associated with the License
    NOTE: Your account will be validated once ALL requirements are verified/met. Thank you for your patience.

Answered Hiding post count

Evan Burck

New Member
AMS Premium
I apologize if this has been answered already, but I wasn't able to find it in a search.

This view counter here: Is there any way to hide it? We only want that to be viewable by admins if possible. I'm not CSS savvy enough to figure that out unfortunately.

1724553098894.png


1724556729282.png
 
Last edited:
Solution
The view count can be enabled/disabled, via AMS Style Properties for each layout type.

Example, here is how to disable the view count on the Carousels (Featured, Latest and Simple).

Admin CP >> Appearance >> Styles & templates >> Style properties >> AMS: appearance >> Featured articles carousel >> Featured articles carousel elements >> Views (uncheck)

Selection_999(176).png


Admin CP >> Appearance >> Styles & templates >> Style properties >> AMS: appearance >> Latest articles carousel >> Latest articles carousel elements >> Views (uncheck)

Selection_999(177).png


Admin CP >> Appearance >> Styles & templates >> Style properties >> AMS: appearance >> Articles carousel simple >> Articles carousel simple elements >> Views (uncheck)

Selection_999(178).png
The view count can be enabled/disabled, via AMS Style Properties for each layout type.

Example, here is how to disable the view count on the Carousels (Featured, Latest and Simple).

Admin CP >> Appearance >> Styles & templates >> Style properties >> AMS: appearance >> Featured articles carousel >> Featured articles carousel elements >> Views (uncheck)

Selection_999(176).png


Admin CP >> Appearance >> Styles & templates >> Style properties >> AMS: appearance >> Latest articles carousel >> Latest articles carousel elements >> Views (uncheck)

Selection_999(177).png


Admin CP >> Appearance >> Styles & templates >> Style properties >> AMS: appearance >> Articles carousel simple >> Articles carousel simple elements >> Views (uncheck)

Selection_999(178).png
 
Solution
The view count can be enabled/disabled, via AMS Style Properties for each layout type.

Example, here is how to disable the view count on the Carousels (Featured, Latest and Simple).

Admin CP >> Appearance >> Styles & templates >> Style properties >> AMS: appearance >> Featured articles carousel >> Featured articles carousel elements >> Views (uncheck)

View attachment 9699


Admin CP >> Appearance >> Styles & templates >> Style properties >> AMS: appearance >> Latest articles carousel >> Latest articles carousel elements >> Views (uncheck)

View attachment 9700


Admin CP >> Appearance >> Styles & templates >> Style properties >> AMS: appearance >> Articles carousel simple >> Articles carousel simple elements >> Views (uncheck)

View attachment 9698
Sorry to dig this old topic up again, but there's still one spot I'm noticing views still shows up despite it being unchecked everywhere. I've tried to find some CSS that'd hide it but I just plain wasn't able to figure it out. What's the best way to hide this one?

1731955744146.png
 
Sorry to dig this old topic up again, but there's still one spot I'm noticing views still shows up despite it being unchecked everywhere. I've tried to find some CSS that'd hide it but I just plain wasn't able to figure it out. What's the best way to hide this one?

View attachment 9916
That one needs to be commented out.

Edit the template xa_ams_article_view

Scroll down towards the bottom of the template until you see the block of code for the article information sidebar block, then simple use the XF comment tag to comment out the lines of template code that displays the view count. Super easy :)
 
Scroll down towards the bottom of the template until you see the block of code for the article information sidebar block...
Find....

<xf:sidebar key="infoSidebar">

This is the article information block ...

This is the block of template syntax the you need to comment out in that sidebar block

HTML:
<xf:if is="$article.view_count">
                    <dl class="pairs pairs--justified">
                        <dt>{{ phrase('views') }}</dt>
                        <dd>{$article.view_count|number}</dd>
                    </dl>
                </xf:if>

Simply wrap it with <xf:comment> tags as shown below...

HTML:
<xf:comment><xf:if is="$article.view_count">
                    <dl class="pairs pairs--justified">
                        <dt>{{ phrase('views') }}</dt>
                        <dd>{$article.view_count|number}</dd>
                    </dl>
                </xf:if></xf:comment>
 
Back
Top