On October 19, 2021, we have enabled single-sign-on for our Plesk Support Center to provide a seamless login/account experience. This implies that you’ll be able to use a single account across any of our web-facing properties.
If you had already registered your account at Plesk 360 (formerly known as My Plesk) please use one for login. Otherwise please re-register it using the same email address as your existing Zendesk login (support account). It’s essential that you use the same email address on our support center to ensure that your tickets stay attached to the same account.

If access WordPress login page using website preview, it is redirected to the original website

Follow

Comments

8 comments

  • Avatar
    Vik

    If we cant login to wordpress's control panel, we can not access to the WordPress dashboard Settings > General section.

    0
    Comment actions Permalink
  • Avatar
    Ivan Postnikov (Edited )

    Hello @Vik, in this article WordPress control panel is accessible.

    Could you, please, share the details, is there any error message shown for you?

    0
    Comment actions Permalink
  • Avatar
    Vik

    sorry, I understood that you can not access Wordpress Dashboard when you tried to sign in.

    Example: you try to access to your preview website in this url:

    I found a easy solution adding this line into the wp-config.php file (before mysql section)

    • define('RELOCATE',true); 

    This is good for me

    Now, I can login to my preview site in plesk and login to Wordpress Dashboard

    I hope this can help others

     

     

     

    0
    Comment actions Permalink
  • Avatar
    Mario

    Hi, 

    Disable https in the live site is not an option: 1) obvious security reasons 2) Google ranking and 3) Google alert of unsafe website (as per July 1st 2018).

    Any workaround?

    Thanks

    0
    Comment actions Permalink
  • Avatar
    Taras Ermoshin

    @Mario Hi!

    This article is devoted to a WordPress website on Plesk which is under development while the production website is working on another server. The article was updated accordingly.

    0
    Comment actions Permalink
  • Avatar
    Taras Ermoshin

    @Vik Hello!

    As I mentioned above, this article is about a WordPress website on Plesk which is under development while the production website is working on another server. While in the WordPress documentation https://codex.wordpress.org/Changing_The_Site_URL , it is stated that the RELOCATE option is intended to be used when the whole website is moved to another server.

    Additionally, I tried using this option on the test WordPress installation, and the URL wasn't changed to the one with http:// both in WP interface and database when I accessed the login page using http://example.com/wp-login.php.

     

    0
    Comment actions Permalink
  • Avatar
    Mario

    Hi guys, 

    @Vik, define('RELOCATE',true);  worked perfectly for me, thanks!

    If WP-admin is not accessible, just make the change in phpMyAdmin:

    to Plesk's preview URL:

    Also, when the site is migrated, check wp-config.php, as sometimes they contain:

    define('WP_HOME','https://www.example.com');
    define('WP_SITEURL','https://www.example.com');

    Do open the preview URL in incognito mode/other browser, as sometimes the cache will still redirect to main URL

    Result:

    Hope it helps!

     

    0
    Comment actions Permalink
  • Avatar
    Robert Asilbekov

    @Mario Proposed workaround will change all links to the Plesk preview URL.

    Regarding "define('RELOCATE',true);" consider the following: 

    == https://codex.wordpress.org/Changing_The_Site_URL

    Important! Leaving the RELOCATE constant in your wp-config.php file is insecure, as it allows an attacker to change your site URL to anything they want in some configurations. Always remove the RELOCATE line from wp-config.php after you're done.

    ==

    0
    Comment actions Permalink

Please sign in to leave a comment.

Have more questions? Submit a request