Skip to content

Instantly share code, notes, and snippets.

@iainp999
Created September 27, 2018 09:38
Show Gist options
  • Save iainp999/3fc7a8904a1ad19c65fe4d959dce6dcb to your computer and use it in GitHub Desktop.
Save iainp999/3fc7a8904a1ad19c65fe4d959dce6dcb to your computer and use it in GitHub Desktop.
Apache: Prevent internal redirect loop
RewriteCond %{ENV:REDIRECT_STATUS} ^$
@iainp999
Copy link
Author

iainp999 commented Sep 5, 2019

Example in context

RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_URI} !=/favicon.ico
RewriteCond %{ENV:REDIRECT_STATUS} ^$
RewriteRule ^ index.php [L]

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment