0

I must update a existing Octobercms project and it has url like this: <a class="page-link" href="{{ 'catalog/category/' | page({'category': category.slug'}) }}" >Все товары</a>

And url in category page is this: url = "/catalog/:category?"

How can I pass two parametres in url I tried this:
<a class="page-link" href="{{ 'catalog/category/' | page({'category': category.slug, 'second_parameter':'1'}) }}" >Все товары</a> and changed url in category page to url = "/catalog/:category?/:second_parameter? but it did not help? Who can help me?

  • Does "it did not help" mean, you got an error message? If that's the case, it would be helpful to share it with us. – shaedrich Apr 08 '21 at 10:59

1 Answers1

2

The important thing is the page's Filename name, as shown in the screenshot

enter image description here

Use it and create a link as shown below, it will work.

enter image description here

{{ 'test-pg'|page({'param1': 'one', 'param2': 'two'}) }}

Output

enter image description here

http://localhost:8000/test-pg/one/two

if any doubt please comment.

Hardik Satasiya
  • 9,547
  • 3
  • 22
  • 40