Can I create a private page that only tagged customers can see (not a private collection)

Clare27
New Member
2 0 0

Hello,

I sell digital PDFs that are sometimes released in stages. Currently I update the PDF as each new bit is added and then my customers get an email with the additions. I'd like to change this so that the new content is accessible to customers who have purchased the original PDF (and I know I can embed PDFs in pages)

I have found and practised changing the code to add a private collection that only tagged customers can see in the hope that I could replicate this for a page, but the page is visible to me whether I am logged in or not, so the checking for tagging is not working as it has done for a private collection. If anyone can tell me where I might be going wrong, or if this is just not possible/ possible another way, I'd be most grateful.

The code I used to create a private collection for tagged customer only was this

{%if customer.tags contains 'vip'%}

{% section 'collection'%}
{% else %}

{{ pages.no-access.content }}

{%endif%}

And the code I tried to use to do the same for a page was this (which I kind of made up, hoping copying/trial and error/crossing my fingers would get me the result I was after, but no!

{%if customer.tags contains 'vip'%}

{{ pages.Xmas SAL 2021 }}
{%else%}

{{ pages.no-access.content }}

{%endif%}

Thanks in advance!

Best wishes,

Clare

Replies 0 (0)