Take the 2-minute tour ×
WordPress Development Stack Exchange is a question and answer site for WordPress developers and administrators. It's 100% free, no registration required.

On localhost (WAMP server) I have installed wordpress in the root directory (examplesite.com). I have an application that needs to run outside of Wordpress, so I would like it in the folder /application (examplesite.com/application). I created the folder “application” in the root, but when I go to the url examplesite.com/application, I get the message “Forbidden you don't have permission to access examplesite/application/< on this server”.

I found a solution suggesting to add the following to my htaccess, but it didn’t work for me.

    <IfModule mod_rewrite.c>
    RewriteEngine On
    RewriteBase /
    RewriteCond %{REQUEST_URI} ^/application/(.*)$ [OR]
    RewriteRule ^.*$ - [L]
    </IfModule>
    # BEGIN WordPress
    <IfModule mod_rewrite.c>
    RewriteEngine On
    RewriteBase /
    RewriteRule ^index\.php$ - [L]
    RewriteCond %{REQUEST_FILENAME} !-f
    RewriteCond %{REQUEST_FILENAME} !-d
    RewriteRule . /index.php [L]
    </IfModule>

    # END WordPress`

Any advice? Thank you in advance!

share|improve this question

2 Answers 2

You can revert to the default WordPress rewrite rules. The line already handles checking for existing physical directories:

RewriteCond %{REQUEST_FILENAME} !-d

Your problem does not lie with WordPress, rather some other problem with your server/htaccess files. You have not provided enough information to solve your problem, but it probly is an issue with file permissions, Deny from rules in htaccess, or Indexes.

share|improve this answer

Try it like that:

<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /
RewriteRule ^index\.php$ - [L]
RewriteCond %{REQUEST_URI} !^/application/
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /index.php [L]
</IfModule>

and additional .htaccess in application folder

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.