Skip to content
● Critical PHP security fixes are out: update PHP on your Grav sites. What to do →

New install having problems with taxonomy pages

first-time

Started by Mark Hanford 8 years ago · 1 replies · 886 views
8 years ago

I have a new Grav install (https://www.cylindric.net) with a couple of extra plugins:

  • taxonomylist
  • simplesearch
  • themer
  • login
  • admin

And I'm using in part the "knowledge-base" theme.

I've noticed that the searches for specific tags and categories don't seem to work, and just give a Grav "404" error.

I'm not using Apache, but CaddyServer, so the .htaccess is kind of different. All other routing seems to be working fine, so I think that is okay, from what I can tell. For example, search URLs such as https://www.cylindric.net/search/query:Home work fine.

Apart from the security protection, the only rule really is

TXT
# global rewrite should come last.
rewrite {
    to  {path} {path}/ /index.php?_url={uri}
}

The URL being spat out by the KB lists look like this:

TXT
https://www.cylindric.net/taxonomy?name=category&val=Tech

Which from my web logs I can see being re-written as

TXT
/index.php?_url=/taxonomy?name=category&val=Tech
8 years ago

Did you try the latest Caddyfile? The rewrite there includes a query-part:

TXT
# global rewrite should come last.
rewrite {
    to  {path} {path}/ /index.php?_url={uri}&{query}
}

Suggested topics

Topic Participants Replies Views Activity
Installation & Hosting · by David Meissner, 13 hours ago
0 21 13 hours ago
Installation & Hosting · by Anthony J Cervo, 5 days ago
3 114 3 days ago
Installation & Hosting · by motorambler, 2 months ago
9 787 4 weeks ago
Installation & Hosting · by jeremycherfas, 1 month ago
1 396 1 month ago
Installation & Hosting · by antoinep, 4 months ago
8 1230 4 months ago