WordPress.org

Ready to get started?Download WordPress

Forums

Changed domain name, updated database, bloginfo function not updated (2 posts)

  1. jrm213
    Member
    Posted 4 years ago #

    I developed a site on a subdomain of another site and have now moved that site to the actual domain it was intended for.

    I backed up the database and restored it on the new server, zipped the httpdocs folder from the subdomain and unzipped it into the new domains httpdocs directory. I restored the database to a new database name. I then updated the wp-config file with the new username, password, and database name. Next I updated options_value's in wp_options replacing the old domain with the new domain. (I have done this many times with other sites and this is all I ever had to do in previous version of wordpress).

    The site does display, but anywhere I have used the bloginfo function in my php it is still pulling the old subdomain address for 'stylesheet-directory', 'stylesheet-url', and 'home' values passed to that function. Also wp-list-pages is pulling with links to the old subdomain url.

    I did some research and updated my wp-config file to contain:
    define('WP_HOME','http://mynewdomain.com');
    define('WP_SITEURL','http://mynewdomain.com');
    this didn't seem to change anything.

    I need to get this working, what did I miss?

  2. stvwlf
    Member
    Posted 4 years ago #

    There are many places in the WP database that are hard coded references to the old site URL's. See this article for some additional SQL queries to run when moving a site.

    http://www.mydigitallife.info/2007/10/01/how-to-move-wordpress-blog-to-new-domain-or-location/

Topic Closed

This topic has been closed to new replies.

About this Topic