Skip to content
Grav 2.0 is officially stable. Read the announcement →
Support

Mod_rewrite help

Solved by Jamie Pickett View solution

Started by Jamie Pickett 6 years ago · 1 replies · 616 views
6 years ago

I have a need for mod_rewrite and specifically using the pass through flag. I am trying to redirect from a URL that does not exist through to one that does, and each time I am returned the Grav 404 page for my site. This is an example of the rule that I am using:

TXT
RewriteRule ^technologies/analytics/gettingstarted/?$ /gettingstarted/analytics/ [PT,L]

If I change the rule up a little to the following, it works:

TXT
RewriteRule ^technologies/analytics/gettingstarted/?$ /test.html [PT,L]

Any help / insight would be appreciated.

6 years ago Solution

I ditched the mod_rewrite and started using the Grav routing.

Updated... Due to a fatal error I am getting with the internal routing, I am back to investigating the mod_rewrites as a solution.

Updated again, figured out why Grav was throwing fatal exception and will address in another issue (/forum/support/fatal-error-when-routing-to-page-that-is-not-found-t3643?u=pickettj)

last edited 09/21/20 by Jamie Pickett

Suggested topics

Topic Participants Replies Views Activity
Support · by Paul Hodges, 4 weeks ago
19 485 5 days ago
Support · by Lauw, 7 days ago
2 101 7 days ago
Support · by Anna, 3 weeks ago
4 426 1 week ago
Support · by gtx, 4 weeks ago
4 377 3 weeks ago
Support · by Anna, 1 month ago
9 484 4 weeks ago