Wordpress 403/404 errors: you do not have permission to access / wp -admin / themes.php on this server

Some background:

This week I set up six blogs using Wordpress 2.92 installed with Fantastico on a rabbit bunny plan with Hostgator.

I used the same theme (Heatmap 2.5.4) and plugins for each blog.

They all worked, no problem.

I am going to create a new blog this morning using the same setting, and when I try to change the theme settings, I get the following error:

Forbidden You don't have permission to access /wp-admin/themes.php on this server. Additionally, a 404 Not Found error was encountered while trying to use an ErrorDocument to handle the request. Apache/2.2.15 (Unix) mod_ssl/2.2.15 OpenSSL/0.9.8n DAV/2 mod_fcgid/2.3.5 mod_auth_passthrough/2.1 mod_bwlimited/1.4 FrontPage/5.0.2.2635 Server at http://www.mydomain.com Port 80 

I tried uninstalling WP and performing a clean install, still the same problem with a clean install.

So, I went back and checked six other blogs that I had configured for the last week or so, and now they give me 403 or 404 errors when trying to change the theme settings, and every time there appears an error that either themes points to. php or functions.php

At this moment, I am in my mind, trying to understand what the problem is. Hostgator support looked at him and thought it was a permissions problem, but they reset those and I still have a problem.

At first, I thought that the problem could be related to the plugin that I recently installed in the previous six blogs that morning (ByREV Fix Missed Shedule Plugin) to deal with a missed schedule error with WP 2.92, and that this may have pounced things up . But then I checked the blog that I built a few months ago, also using the same theme and plugins, and now it also faces the same problem.

Any ideas? I tried removing htaccess by loading empty, loading it using this snippet, which I found on the forum for the host site:

 # BEGIN WordPress <IfModule mod_rewrite.c> RewriteEngine On RewriteBase / RewriteCond %{REQUEST_FILENAME} !-f RewriteCond %{REQUEST_FILENAME} !-d RewriteRule . /index.php [L] </IfModule> # END WordPress 

Nothing worked. I still get 403 or 404 errors every time. Everything worked fine yesterday, so I know this setting works, I just did something, and I don’t know what it is.

I read the linked stream here and tried chmoding wp-content folder to 0755 and still have a problem.

Any thoughts? Thanks!

+7
wordpress .htaccess
source share
9 answers

The first mistake you get - permissions - is the most revealing. Bump wp-content and wp-admin to 777 and try, and if that works, then change both of them to 755 and see if everything works. What do you use to change folder permissions? FTP client?

0
source share

A few years later, but I have a solution for the latest version of WordPress that has the same problem (files with the .htaccess extension created by WordPress are renamed to 403 forbidden error messages). Here's what WordPress looks like:

 # 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 

The problem is that the condition is not working. This does not work because the module he is looking for is not .c , it .so . I think this is a platform-specific or configuration-specific issue when Mac OS and Lunix Apache installations are configured for .so AKA 'shared-object' modules. The search for the .c module should not interrupt the condition, I think it is an error, but a problem.

Just change mod_rewrite.c to mod_rewrite.so and you're done!

 # BEGIN WordPress <IfModule mod_rewrite.so> RewriteEngine On RewriteBase / RewriteRule ^index\.php$ - [L] RewriteCond %{REQUEST_FILENAME} !-f RewriteCond %{REQUEST_FILENAME} !-d RewriteRule . /index.php [L] </IfModule> # END WordPress 
+21
source share
+3
source share

Just to keep track, the problem is solved! I mentioned the mod_sec parameters for my server as a possible culprit, as suggested, and they were able to fix this problem. Here is what the technical agent said to tell them when you go to support:

Just let them know that you need the 340163 whitelisted rule for the .com domain as its violation of the mod_sec rule.

Obviously, you will need to do this for every domain that has a problem, but it works. Thanks to everyone for all the suggestions!

+2
source share

You have the best of luck ... I had the same problem, but I had more technical knowledge on this issue, and I was able to determine that this is a mod_sec problem, which the host server should fix / use the whitelist itself. You cannot do it yourself. Just ask hostgator technology to check mod_sec parameters on your server.

Enjoy the fixed problem, D

+1
source share

Have you tried:

 <Directory /path/to/your/wp-admin> Order allow,deny Allow from all </Directory> 
0
source share

I hope people find this answer, since there are many, many posts on the Internet about this. Many people have suggested that this is a .htaccess problem, and for me it was. However, I searched in .htaccess in the root, and not in .htaccess in the wp-admin folder. I usually work on this site, in particular, through terminal services, so when it downloaded me and I couldn’t log in, I tried to access it from my home computer (and its IP).

I was foolishly forgotten by the IP restriction that I placed in the wp-admin.htaccess file.

 AuthName "Protected" AuthType Basic <Limit GET POST> order deny,allow deny from all allow from 11.11.11.11 </Limit> 

If there is something similar in your wp-admin.htaccess files, this will easily explain why all the sites on which you work ceased to function at the same time. Internet service providers sometimes rotate IP addresses, so no one starts a server from home without paying for it.

0
source share

I had the same problem but nothing worked above ... try a really simple solution ...

Back up the .htaccess file. Remove it from the root directory. Then try accessing these directories. It is likely that all the rewriting conditions that you had in your file cause access problems. The index page should be automatically selected on most hosts .: P

0
source share

Try disabling ModSecurity on your cPanel. Log in to your cPanel. Find the Security category. There you can find the ModSecurity link. Click on it and disable it for the domain that you encountered error 403.

Using this method, you can also resolve some 403 errors. Go to your WordPress dashboard, settings> Permalink and just click Save.

Hope this helps. :)

0
source share

All Articles