Create a private collection

Create a private collection

PAUL8
Tourist
63 0 19

Hello,

I want to create a private collection on my store, so only people with an account can access the collection. I also want to mask the private collection article everywhere on the website. So it just can be accessible in the private collection menu.

I use dawn theme, this is my website: womber.fr and the password is PROPAGANDAAA

Thanks, 

Cordially,

Replies 7 (7)

VIEKIN
Shopify Partner
779 93 111

To achieve function you need assign for each user a tag, then when user login you can check if user has the tag will show the collection if the user has not tag or not login the collection will hide.

You can please Like and Accepted Solution if my suggestion helpful. And if you want to customize or develop new feature on Theme or App => Contact to us via Email or Skype.
- Contact Support : Gmail | Skype: live:.cid.309f2fbaceec513
PAUL8
Tourist
63 0 19

What is the code to add in what files to made this happens, because I added the tag but it’s not working…

VIEKIN
Shopify Partner
779 93 111

You need to check in code at the file handling show menu.

 

 

{% assign statusShow = false %}
{% for tag in customer.tags %}
  {% if tag contains 'abc' %}
     {% assign statusShow = true %}
  {% endif %}
{% endfor %}

 

 

Then you can check if statuShow == true => make the collection show and opposite hide that collection

You can please Like and Accepted Solution if my suggestion helpful. And if you want to customize or develop new feature on Theme or App => Contact to us via Email or Skype.
- Contact Support : Gmail | Skype: live:.cid.309f2fbaceec513

BSS-TekLabs
Shopify Partner
2350 702 828
  {% if collection.handle == 'womber-x-spicyv' %}
    {% if customer == null %}
      <script>
        window.location.href = "/account/login";
      </script>
    {% endif %}
  {% endif %}

If our suggestions are useful, please let us know by giving it a like or marking it as a solution.


Salepify: Efficiently increase sales conversion with sale-driven features like auto add to cart, free gifts (free plan available)


Salemate: Boost your AVO with 2-layer offer, countdown upsell in your post purchase page


BSS Commerce - Full-service eCommerce Agency | Use Shopify for 1$ in the first month now
BSS-TekLabs
Shopify Partner
2350 702 828

- Here is the solution for you @PAUL8 
- Please follow these steps:
1. Go to Online Store --> Theme --> Edit code.
2. Open your theme.liquid file
3. In theme.liquid, paste the below code before </head> and press 'Save' to save it

  {% if collection.handle == 'womber-x-spicyv' %}
    {% if customer == null %}
      <script>
        window.location.href = "/account/login";
      </script>
    {% endif %}
  {% endif %}

- change womber-x-spicyv to collection you want make private

- Please press 'Like' and mark it as 'Solution' if you find it helpful. Thank you.

If our suggestions are useful, please let us know by giving it a like or marking it as a solution.


Salepify: Efficiently increase sales conversion with sale-driven features like auto add to cart, free gifts (free plan available)


Salemate: Boost your AVO with 2-layer offer, countdown upsell in your post purchase page


BSS Commerce - Full-service eCommerce Agency | Use Shopify for 1$ in the first month now
PAUL8
Tourist
63 0 19

Hello,
It's not working...

BSS-TekLabs
Shopify Partner
2350 702 828

Can you send me the link of the collection you want to make private, I will send you the code again.

If our suggestions are useful, please let us know by giving it a like or marking it as a solution.


Salepify: Efficiently increase sales conversion with sale-driven features like auto add to cart, free gifts (free plan available)


Salemate: Boost your AVO with 2-layer offer, countdown upsell in your post purchase page


BSS Commerce - Full-service eCommerce Agency | Use Shopify for 1$ in the first month now