skip to Main Content

I’m new at this and today I wanted to change my hosting’s main domain from blog.mywebsite.com (was running ok) to mywebsite.com. Before entering CPanel I have a page on my hosting that gives me the option to change the domain so I did it.

The problem is now I’m getting a page that says: The website is not properly configured on this server
If you are the owner of this website, please contact your hosting provider

I believe that forcing a domain change like that isn’t the correct way to do it so here I am looking for some help 🙂

ps: I have my WordPress completely backed up with plugin Duplicator from blog.mywebsite.com so I’m up to erase everything. Also on my DNS Manager I can see blog.mywebsite.com and mywebsite.com pointing to the same IP.

UPDATE
I deleted the blog.mywebsite.com from the DNS Manager and now it loads mybesite.com but without any image/CSS.

3

Answers


  1. in wp-config.php

    define( 'WP_SITEURL', 'mywebsite.com' );
    define( 'WP_HOME', 'mywebsite.com' );
    
    Login or Signup to reply.
  2. Normally at first you need to change your WordPress location using wordpress control panel and move the files to public_html directory .

    Now in this case define the wordpress directory location in wp-config.php file

    define( 'WP_SITEURL', 'mywebsite.com' );
    define( 'WP_HOME', 'mywebsite.com' );
    
    Login or Signup to reply.
  3. You can update your WordPress site URL by adding code in wp-config.php or removing URL completely from the database using search and find plugin.

    Or you can use MySQL script to change URL

    UPDATE wp_options SET option_value = replace(option_value, 'http://www.oldurl.com', 'http://www.newurl.com') WHERE option_name = 'home' OR option_name = 'siteurl';
    
    UPDATE wp_posts SET guid = replace(guid, 'http://www.oldurl.com','http://www.newurl.com');
    
    UPDATE wp_posts SET post_content = replace(post_content, 'http://www.oldurl.com', 'http://www.newurl.com');
    
    UPDATE wp_postmeta SET meta_value = replace(meta_value,'http://www.oldurl.com','http://www.newurl.com');
    

    You can also refer to this Article How to Change Website URL Without Accessing the wp-admin Panel

    How to Configure a WordPress Website After its Migration

    Login or Signup to reply.
Please signup or login to give your own answer.
Back To Top
Search