Back to Catalog Support

Fibonacci
Fibonacci

I need to display default product list if the param is 'default' (This param used for specifie category). How to? I just can display the product list when the param is match in category (cannot setup default category on dynamic category).

Tiipiik
Tiipiik

Hi,

I'm not sure to understand your problem and what you want to achieve.

Dynamic category is provided by the {{:slug }} parameter, and products are retrived from the relation between products and categories.

The category filter is only used when you aren't in a category and you want to display products (for example on a home page you can display products of a specific category).

Can you be more precise on what you want to do and/or contact me by email and give me access to your OctoberCMS backend ?

Fibonacci
Fibonacci

I have products.htm and the url is products/:category. I have a few categories (e.g):

  1. Cats
  2. Dogs

In layout code I have this: <li><a href="{{ 'products'|page }}">PRODUCTS

and it will generate the link 'products/default'

I know when I access the url 'products/cats, It will display the products of a cats category.

But, I got a problem. How to display 'cats category' as default url (products/default)?

Last updated

Tiipiik
Tiipiik

Sorry for the late, I did not see your answer.

Why do you want to make a page with products/default ?

Did you mean your categories urls are generated as "product/default" instead of "products/cats" ?

1-4 of 4