Skip to main content

Hide Newly created product by the App

Collection template

Find any “for” loops for “products” in the collection:

{% for product in collection.products %}

Add this snippet right after the opening of the loop:

{% if product.type == 'PPLR_HIDDEN_PRODUCT' %}{% continue %}{% endif %}

Sometimes, there are multiple collection templates, and this change should be applied to each template.

Find any “for” loops for “items” in the search results:

{% for item in search.results %}

Add this snippet right after the opening of the loop:

{% if item.type == 'PPLR_HIDDEN_PRODUCT' %}{% continue %}{% endif %}

Find any “for” loops for “products” in the template:

{%- for product in predictive_search.resources.products -%}

Add this snippet right after the opening of the loop:

{% if product.type == 'PPLR_HIDDEN_PRODUCT' %}{% continue %}{% endif %}

Related-Products template

Find any “for” loops for “recommendations” in the template:

{% for recommendation in recommendations.products %}

Add this snippet right after the opening of the loop:

{% if recommendation.type == 'PPLR_HIDDEN_PRODUCT' %}{% continue %}{% endif %}