• Resolved kiriwillis

    (@kiriwillis)


    I’m working to copy an existing WordPress site to a new domain for a rebranding project. Both sites are hosted on the same server with the same hosting provider (DreamHost).

    I exported the database of old site (via phpMyAdmin) and downloaded all the files (via FileZilla). I then imported the database to the new site (via phpMyAdmin) and uploaded the old files (via FileZilla). I also went into the wp-config.php and updated all the credentials.

    When I go to the new site everything works great – all my links are working and everything looks great. The issue now is that when I go to the WordPress admin page of the new site (newsite.com/wp-admin) it is redirecting me to the old admin page (oldsite.com/wp-admin).

    What step did I miss along the way and how do I fix this issue?

Viewing 5 replies - 1 through 5 (of 5 total)
  • Have you updated the siteurl and home options in wp_options table? You can do it through phpMyAdmin. Set it to the absolute path to your new site. For example, https://www.example.com

    Thread Starter kiriwillis

    (@kiriwillis)

    lamosty – thanks for the quick response.

    I think what my issue is, is that when I imported the database it created new tables and didn’t overwrite the existing tables. For examples I have:

    wp_123456_options (created during WordPress installation) and wp_234567_options (imported database)

    It is clear that WordPress is looking at the siteurl for the new options table from the imported database.

    I guess the cleanest thing might be to blow-up all the tables when the new database was created during the Word Press installation. Then update the rows the appropriate data.

    Thoughts?

    If you exported the whole database, it will import all the tables with the same names as in the old database (such as your wp_234567_options). I think it is enough to change $table_prefix variable in wp-config.php. to the wp_234567_. Then your WordPress on the new site should use the imported tables (using its prefix), not the tables it created during installation (with wp_123456_ prefix)

    Thread Starter kiriwillis

    (@kiriwillis)

    Rastislav,

    Thanks for the help. I’m now able to get into WordPress administration.

    Willis

    Great. Please mark your topic as resolved.

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘WordPress Site Migration – WPAdmin Redirect’ is closed to new replies.