• Resolved Freshwater Creative Mike

    (@freshwater-creative-mike)


    Hey guys,
    Ok, so myself and out little company made a website for a local auto body place on the back end of our site. Construction went well. looks cool, etc. Now, we have to move the site to their domain, server, etc. Here is what I did, and the chaos that became of it:

    I changed the url on our back-end version to match their new domain, and downloaded the whole project. wordpress and all. i then edited the wp_config file to reflect their database, and uploaded it. Here are my issues.

    On our back-end version i needed to reset the url. so I went into the wp-config file and set them there manually. Now my navigation goes to our live site instead of where its supposed to.

    The clients site shows the pages we have made once you log in, but it does not show our changes and stuff. just a basic theme. I need help!

    My back-end site:https://freshwatercreative.com/backerauto/
    Customers site: backerauto.com

    ANy ideas?

    -Mike

Viewing 7 replies - 1 through 7 (of 7 total)
  • i then edited the wp_config file to reflect their database…

    You need to move the database to the new hosting account, not link to it remotely; many webhosts don’t allow remote MySQL database access.

    Hello Mike, I hope the weather is nice where you are currently located. Take a deep breath and we’ll get you sorted out ??

    Okay, let’s start by getting some details.

    1) Before downloading the site from your back end, did you go to Settings > General and change the URLs to the live server? If so, good.

    2) As indicated, your client has a mySQL database set up. However, did you export the tables from your database and import them into theirs?

    Mike, you sound like you know what you’re doing, but at the risk of telling you something you may already know, this is the step by step process I follow when moving WordPress.

    Step 1: Log into the backend of the demo site. Go to Settings > General and change the URLs to where your site is going to be located.

    (Note: be sure that the URLs are correct as once you press Save Changes, the site will be out of action.)

    Step 2: Via FTP, download your entire WordPress site to your computer.

    Step 3: Log into your hosting cPanel. Depending on your host, you’re either going to find your mySQL database and then click something to the extent of, “Edit in phpMyAdmin”, or you’re going to log into phpMyAdmin and select your database from the left hand pane.

    With your database selected, click the export tab. Make sure these are the defaults.

    Export section:
    – All tables selected
    – radial SQL button selected

    Options > Structure section:
    – Structure selected
    – Add AUTO_INCREMENT value selected
    – Enclose table and field names with backquotes selected

    Options > Data section:
    – Data selected
    – Use hexadecimal for BLOB selected

    At the bottom, select Save as File, name the file name template whatever you’d like, and use no compression.

    Press Go.

    Step 4: Time to set up a database on your clients server. Once it’s set up, get into their phpMyAdmin for the database and go to the import tab.

    Select the sql file from your hard drive and press Go.

    Step 5: In the downloaded copy of their site, edit the wp-config file. Edit the DB_NAME, DB_USER, DB_PASSWORD, and DB_HOST to match the clients database.

    Step 6: Upload the site to your clients’ server via FTP.

    Step 7:
    Also upload this file: https://interconnectit.com/products/search-and-replace-for-wordpress-databases/ You need it do update all the URLs in the database pointing at your old server.

    Once uploaded, go to example.com/search-and-replace.php (or whatever you name the file) and go through the steps. It will read the wp-config file and automatically know what database you’re trying to deal with. Go through the steps, have all the tables selected, and when it asks what you want it to search, put your demo server’s url (reshwatercreative.com/backerauto). Do not add any unnecessary characters like the slash at the end or the http. Replace it with the new url (backerauto.com).

    Once done, delete the search and replace file and you should be done!

    (Note the search and replace won’t find any direct references in your theme files. So if you direct linked something in your header.php file, you’ll need to update that manually.)

    Troubleshooting:
    Common issues I come across:

    All pages other than home in the nav lead to a 404.
    – Go to Settings > permalinks and put it back to default, press save, then put it to your preferred setting.

    Still some references back to the old server.
    – Remember the search and replace was only for the database. If you’ve edited theme files with full urls, you’ll need to update those. I recommend using some kind of text editor that has a “find”, and “replace all” option.

    Site has elements from the old site.
    -Empty your browsers cache, cookies, and history.

    Good luck Mike, I hope this helps! ??

    Thread Starter Freshwater Creative Mike

    (@freshwater-creative-mike)

    When I go to import our downloaded database into theirs I get this error:

    SQL query:


    — Database: freshwa_backerauto

    CREATE DATABASE freshwa_backerauto DEFAULT CHARACTER SET latin1 COLLATE latin1_swedish_ci;

    MySQL said: Documentation
    #1044 – Access denied for user ‘backera_backer’@’localhost’ to database ‘freshwa_backerauto’

    Thank you for all the help so far.

    -Mike

    When you create the new, empty database on the new host, grant all privledges to the user backera_backer. Look in the database area of Cpanel to do that.

    Or change the user name in the database dump. See https://support.hostgator.com/articles/cpanel/how-to-import-your-mysql-database

    Or create a new database on the new host with the same user name as the old database and be sure and grant all privledges.

    Ask the webhost for help with the cpanel and database creation.

    Thread Starter Freshwater Creative Mike

    (@freshwater-creative-mike)

    I am going to have to talk to the host. When I got to create the database it tells me the database already exists. so I change the name in the sql document, and it goes to create a new database, then tells me i do not have permission. Rough day here.

    -Mike

    Thread Starter Freshwater Creative Mike

    (@freshwater-creative-mike)

    Thank you so much for the help everyone. Onii-chan, songdogtech, you guys are life savers.

    -Mike

Viewing 7 replies - 1 through 7 (of 7 total)
  • The topic ‘Problems moving site to new server.’ is closed to new replies.