• Hi all,

    How to rename the url of a subdamin website to the url of the old hosting domain

    I have tried following steps without success;

    Remark:
    The website of the old hosting domain has been deleted

    -> Settings -> General

    1)
    renamd
    WordPress Address (URL) – https://old hosting domain url

    2)
    renamd
    Site Address (URL) – https://old hosting domain url

    -> Save Changes

    It didn’t work

    On cPanel “File Manager”
    (/home/nowgolic)
    ….
    ….
    /public/html/
    subdomain-1
    subdomain-2
    subdomain-3
    new_hosting_domain
    subdomain-4
    subdomain-5
    ….
    etc

Viewing 2 replies - 1 through 2 (of 2 total)
  • Hi @satimis02

    You have to update all the references from the old URL with the new URL. You can do it following this tutorial: Changing The Site URL

    Have a nice day

    Thread Starter satimis02

    (@satimis02)

    Hi Jesús Amieiro

    Thanks for your advice and the link attached.

    Have tried;
    # Steps

    1.    Edit the wp-config.php file.
    2.    After the “define” statements (just before the comment line that says “That’s all, stop editing!”), insert a new line, and type: define('RELOCATE',true);
    3.    Save your wp-config.php file.
    4.    Open a web browser and manually point it to wp-login.php on the new server. For example, if your new site is at https://www.yourdomainname.com, then type https://www.yourdomainname.com/wp-login.php into your browser’s address bar.
    5.    Login as per normal.
    6.    Look in your web browser’s address bar to verify that you have, indeed, logged in to the correct server. If this is the case, then in the Admin back-end, navigate to Settings > General and verify that both the address settings are correct. Remember to Save Changes.
    7.    Once this has been fixed, edit wp-config.php and either completely remove the line that you added (delete the whole line), comment it out (with //) or change the true value to false if you think it’s likely you will be relocating again.

    Add following lines at the bottom of wp-config.php

    define( 'WP_HOME', 'https://old hosting domain url' );
    define( 'WP_SITEURL', 'https://old hosting domain url' );

    I couldn’t find the line saying;
    That’s all, stop editing!

    I add following 2 lines at the end of the file;

    define('RELOCATE',true);
    # That’s all, stop editing!

    On Chrome run;
    https://old hosting domain url/wp-login.php

    Warning:
    Sorry, this page doesn’t exist.
    Please check the URL or go back a page.
    404 Error. Page Not Found.

    Advice would be appreciated. Thanks

    Regards

    • This reply was modified 3 years, 3 months ago by satimis02.
Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘How to rename the url of a subdamin website to the url of the old hosting domain’ is closed to new replies.