Welcome Guest, Not a member yet? Register   Sign In
Apache Location Directive and URL Rewrite
#1

[eluser]bretticus[/eluser]
Hoping someone else has some insight here to share...

I have an apache configuration file with:

Code:
<FilesMatch "\.php$">
  php_value auto_append_file /path/to/file
</FilesMatch>

I have a managerial controller called "utils." I need to exclude it from the auto append above.

Currently, I have tried:
Code:
<LocationMatch "^/utils(.*)$">
  php_value auto_append_file none
</LocationMatch>

My rewrite rules are:

Code:
RewriteEngine On
RewriteBase /
    
RewriteCond %{REQUEST_URI} ^system.*
RewriteRule ^(.*)$ /index.php?/$1 [L]
    
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond $1 !^(index\.php|images|robots\.txt|css)
RewriteRule ^(.*)$ index.php?/$1 [L]

Do I need to try and match the internal URL? (A.K.A. "index.php?/utils.*") Anyone have experience matching CI URLs in apache configs?

Many thanks.




Theme © iAndrew 2016 - Forum software by © MyBB