simple-php-router
simple-php-router copied to clipboard
Suggest using FallbackResource from mod_dir instead of existence checks with mod_rewrite
With the introduction of https://httpd.apache.org/docs/trunk/mod/mod_dir.html#fallbackresource , many have now moved away from the popular mod_rewrite solution to map non-existent files/folders onto something like index.php, towards using FallbackResource. I find it also much more readable and simple. It can also prevent having to enable the rewrite module, which is one of the modules that cause the slowness that some people claim Apache has (its performance is actually similar to nginx if you disable all the modules and settings in apache that nginx doesn't have).
I wouldn't mind sending in a PR to add both options or to replace the existing suggestion for .htaccess, but I thought it would be better for me to first ask :)
Hi Bert.
Thanks for the great suggestion. Personally I haven't used Apache for a long time, so haven't kept up with all the latest developments on that front however thanks to users like yourself there's instructions for many different web-servers.
If you wouldn't mind, please feel free to share the new behaviors - maybe it can be helpful for those out there that just want to get their project up and running without reading through the Apache manual :)
/ skipperbent
Hi @bertvandepoel,
are you still interested in creating a PR or should I dive into the Apache topic?
~ Marius
It's the same to me. Either of us can do it, it's just editing the README I assume, or were there some other docs that need editing too
I think you are more into the topic. You can either write me the content here or create the PR yourself. Thank you!
~ Marius
Hey @bertvandepoel,
hope you are doing good? Did you have time to collect the changes that have to be made?
~ Marius