It depends on your theme really, but you’re going to be looking in page.liquid in your templates folder. When you open it up, you may see something like this:
{% section 'page-template' %}
In this case you’ll be looking to open page-template.liquid in your sections folder. In either case, you’ll be looking for page.content:
{{ page.content }}
It’ll look something like that. You can put a condition around that guy and use the handle of your page. Let’s say you wanted to hide the contents of the about us page to all but any customer tagged ‘vip’. You could do so like:
{% assign vip = false %}
{% if customer.tags contains 'vip' %}
{% assign vip = true %}
{% endif %}
{% if page.handle == 'about-us' %}
{% if vip %}
{{ page.content }}
{% else %}
Sorry you must be a VIP to access this content
{% endif %}
{% else %}
{{ page.content }}
{% endif %}
Is it because you have two sets of customer tags, ‘vip’ and ‘non-vip’?
With the above code, if you have any other customer tag that includes the letters ‘vip’ in the tag, the ‘contains’ operator will fire as true. You can get around this by replacing ‘contains’ with ‘==’.
Otherwise, it could be because it’s a page that is not ‘…pages/about-us/’ - as the VIP check code is only called for that page, though I don’t know why you’d be seeing the ‘Sorry’ message as well.
{% if customer.tags contains "VIP" %}
{% include 'vip-content' %}
{% else %}
Sorry. You must be a VIP to access this content.
{% endif %}
{% for tag in customer.tags %}
{% if tag == page.handle %}
{% include 'vip.content' %}
{% else %}
Sorry. You must be a VIP to access this content.
{% endif %}
{% endfor %}
Note - these are two separate use cases. You’d only use the section for a single page, or the section for multiple pages, you wouldn’t use both code sections.
This only works if you build your page content manually. If you use a template and add sections, - whatever is added through theme editor will be visible.