Query Params not working in new PHP routing

Wappler: 7.7.4
OS: MacOS Silicon
Server: PHP

I have switched a project to use the new routing and it’s all working nicely apart from Query Params in friendly URLs.

I have a route set up like this:

And when I try to access the catid param (eg. {{query.catid}}) it has no value.

This is completely holding me up as the site requires these variables to function.

Am I doing something wrong? Or is this an issue?

It seems the ac:route meta tag is missing from your content page.
You can add it on the page and the problem will be fixed:

<meta name="ac:route" content="/category/:catid">

we will check and fix auto-adding it on the pages.

1 Like

Thanks @Teodor. I had already tried that and it didn’t make a difference. However, I’ve now spotted that this was in my layout file:

<meta name="ac:route" content="/">

I’m guessing because it was previously using the old routing method. I’ve removed that line and it’s now working.

If these two aspects, adding the line to the content page and removing it from the layout page, could be automated then it will save a lot of head scratching.

Fixed in Wappler 7.7.5
The meta tag will be properly added on the content pages on save and removed from the main pages with the new routing.

This topic was automatically closed 2 days after the last reply. New replies are no longer allowed.