Forbidden You don't have permission to access /wp-login.php on this server

前端 未结 9 1975
天命终不由人
天命终不由人 2020-12-30 03:31

I have one problem with all my WordPress\'s sites. I can access in all and navigate in the posts, pages and other. But when I go to wp-login.php I view the form

相关标签:
9条回答
  • 2020-12-30 03:43

    Change .htaccess file code by this code :

    # BEGIN WordPress
    RewriteEngine On
    RewriteBase /
    RewriteRule ^index\.php$ - [L]
    
    # uploaded files
    RewriteRule ^([_0-9a-zA-Z-]+/)?files/(.+) wp-includes/ms-files.php?file=$2 [L]
    
    # add a trailing slash to /wp-admin
    RewriteRule ^([_0-9a-zA-Z-]+/)?wp-admin$ $1wp-admin/ [R=301,L]
    
    RewriteCond %{REQUEST_FILENAME} -f [OR]
    RewriteCond %{REQUEST_FILENAME} -d
    RewriteRule ^ - [L]
    RewriteRule ^[_0-9a-zA-Z-]+/(wp-(content|admin|includes).*) $1 [L]
    RewriteRule ^[_0-9a-zA-Z-]+/(.*\.php)$ $1 [L]
    RewriteRule . index.php [L]
    # END WordPress
    
    0 讨论(0)
  • 2020-12-30 03:48

    This should work :

    The instructions says that you add a separate .htaccess containing the lines above to the wp-admin folder - and leave the main .htaccess, in the root, alone.

    if that don't help , you can try this:

    copy the .htaccess file as is from the wp-admin and placed it in the root folder and bingo! It should work ! if you face new error after this let us know.

    for reference you can look here as well:

    http://wordpress.org/support/topic/you-dont-have-permission-to-access-blogwp-loginphp-on-this-server

    Check using this:

    <IfModule mod_security.c>
    SecFilterEngine Off
    SecFilterScanPOST Off
    </IfModule>
    
    0 讨论(0)
  • 2020-12-30 03:55

    Make sure your apache .conf files are correct -- then double check your .htaccess files. In this case, my .htaccess were incorrect! I removed some weird stuff no longer needed and it worked. Tada.

    0 讨论(0)
  • 2020-12-30 03:56

    I had a similar error, which was fixed by adding:

    Options FollowSymLinks
    

    ... in the apps/[app-name]/conf/httpd-app.conf file. This is because, in my case, an .htaccess file wants to use rewrite rules, that are not allowed with FollowSymLinks AND SymLinksIfOwnerMatch turned off.

    If your conf file already has a line with Options ..., you can just add FollowSymLinks to the list of options. You could end up with something like this:

    Options Indexes MultiViews FollowSymLinks
    
    0 讨论(0)
  • 2020-12-30 03:58

    Make sure the following lines are not in your wp.config

    define( 'FORCE_SSL_LOGIN', true );
    define( 'FORCE_SSL_ADMIN', true );
    define( 'DISALLOW_FILE_EDIT', true );
    

    I got locked out after deactivating iThemes security plugin

    0 讨论(0)
  • 2020-12-30 03:58

    Sometimes if you are using some simple login info like this: username: 'admin' and pass: 'admin', the hosting is seeing you as a potential Brute Force Attack through WP login file, and blocks you IP address or that particularly file.

    I had that issue with ixwebhosting and just got that info from their support guy. They must unban your IP in this situation. And you must change your WP admin login info to something more secure.

    That solved my problem.

    0 讨论(0)
提交回复
热议问题