On 12/03/2024 20:45, Dave Wreski wrote:
If I understood correctly you want the resulting path to be loaded by your php-fpm backend.Do you have a fallbackresource, such as: "FallbackResource /index.php" or similar? If not, then you may want to add it.Yes, that's correct, I'm using php-fpm. I don't currently have a fallbackresource. I'll add it, if necessary, but I'd also like to identify the actual source reason why it's happening in the first place. How do I troubleshoot this further?Thanks, Dave
What I would do is RewriteRule with just [L] tag for internal redirection or [R,L] if you don't mind the redirection to be external.
Since I haven't seen the whole configuration my guess is you don't have the proper handler defined for the resulting url and that's why you get a 404, and in those cases a is when fallbackresource is ideal, to hand those requests to where they must end.
Generally when I use passthrough [PT] is because the end url will be dealt with the appropiate handler, but you don't seem to have a rule for the destination to be handled in php, so how come you expect anything else other than a 404?
That is briefly what I would do: First make the proper redirections: RewriteEngine on RewriteMap lsv2ids "txt:/etc/httpd/conf.d/linuxsecurity-lsv2ids.map" RewriteRule "/content/view/(.*)" "${lsv2ids:$1}" [R,L]Define the fallback for requests not ending in PHP but for which I hand the php handler to deal them.
FallbackResource /index.php Define the handler for php file requests <FilesMatch \.php> SetHandler "proxy:unix:/run/php-fpm/linuxsecurity.sock|fcgi://localhost" </Filesmatch> --------------------------------------------------------------------- To unsubscribe, e-mail: users-unsubscribe@xxxxxxxxxxxxxxxx For additional commands, e-mail: users-help@xxxxxxxxxxxxxxxx