WordPress Development Stack Exchange is a question and answer site for WordPress developers and administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I have wordpress installed in a subfolder and using permalinks but I'm getting a blank page when I try to access to any post.

This is what I have in the root folder .htaccess:

RewriteEngine On
RewriteCond %{HTTP_HOST} ^(www.)?site.com$
RewriteCond %{REQUEST_URI} !^/wordpress/
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.*)$ /wordpress/$1
RewriteCond %{HTTP_HOST} ^(www.)?site.com$
RewriteRule ^(/)?$ wordpress/index.php [L]

And this is what wordpress put in the subfolder .htaccess:

# 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]

# END WordPress

I'm using custom permalinks with /%postname%.html, the posts have the permalink correctly but when I try to access it shows only an empty blank page.

share|improve this question
what happens when you remove root .htaccess and just use the one in the subfolder? (as a test - i understand the root one is needed too) - I think the two are conflicting. – George Pearce Feb 1 '12 at 1:44
If I remove the .htaccess in root the domain just dont look for index in the root folder. – Shixons Feb 1 '12 at 2:04
did it worked BEFORE the permalik change ? did you configured the wp URL/folder and blog URL/folder in options ? – krembo99 Feb 1 '12 at 4:12
The permalink was always working, the problem its the code in the root .htaccess to redirect to the subfolder. – Shixons Feb 1 '12 at 4:42
Do you want to show up your blog on main domain keeping all files in subdirectory ? – amit Jul 9 '12 at 8:52

try using a blank htaccess file in your root folder and from there you can do a 301 redirect to your WP folder. i have had the same kind of issues with some hosts and always solved that way, it's not WP, it's always a faulty htaccess

share|improve this answer
¿How I do 301 redirect? – Shixons Feb 1 '12 at 2:05
you can do it via your control panel or you can simply take a look at tamingthebeast.net/articles3/spiders-301-redirect.htm (since it depends on your site and there are several options) – Devin Feb 1 '12 at 2:09
I'm using cPanel and it say that I can't make a 301 redirect of the main domain. – Shixons Feb 1 '12 at 4:43

Your Answer


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.