Welcome Guest, Not a member yet? Register   Sign In
.htaccess stuff

Here is my .htaccess file. The line with the arrow disallows accessing php files via http. Is there a command I could add that would allow it for a specified controller?

So if the url was http://mysite.com/api/categories.php, could I disable this for anything after /api/ ?

Options -Indexes
Options +FollowSymLinks
# Set the default file for indexes
DirectoryIndex index.php
<IfModule mod_rewrite.c>
    # mod_rewrite rules
    RewriteEngine on

    # If the file is NOT the index.php file
    RewriteCond %{REQUEST_FILENAME} !index.php

    # Hide all PHP files so none can be accessed by HTTP
    RewriteRule (.*)\.php$ index.php/$1                          // <------------
    # If the file/dir is NOT real go to index
    RewriteCond %{REQUEST_FILENAME} !-f
    RewriteCond %{REQUEST_FILENAME} !-d
    RewriteRule ^(.*)$ index.php/$1 [QSA,L]
# If Mod_ewrite is NOT installed go to index.php
<IfModule !mod_rewrite.c>
    ErrorDocument 404 index.php

Messages In This Thread
.htaccess stuff - by El Forum - 04-24-2009, 09:47 AM
.htaccess stuff - by El Forum - 04-24-2009, 12:01 PM
.htaccess stuff - by El Forum - 04-24-2009, 01:24 PM
.htaccess stuff - by El Forum - 04-24-2009, 02:35 PM

Theme © iAndrew 2016 - Forum software by © MyBB