0

I have a structure section with entry url format: "products/{slug}". All entries have they urls like "/products/category1/subcategory1/product1".

Currently, I have a header navigation which opens product category pages like "products/category1".What is the preferred way to define "/product" page?

1 Answer 1

1

You have to select the "level" in the structure. Im guessing the products are always on level 4? If so you could try this:

{% set entries = craft.entries.section('yourSectionHandle').level(4) %}

{% for entry in entries %}
    ...
{% endfor %}

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.