DataHearth
DataHearth

Reputation: 504

Migration problems with WordPress

We've got troubles with a migration of our website project. We've migrated it to a local server (University) but we can't access to any pages of our website. I think that's a problem of redirection with our pages. For the home page, we've got error 404 and when we're trying to connect to the other pages, not found, the requested url /index.php was not found on this server. On the "original server", it's working perfectly but even if I hard code the new url of our server in wp-config.php, it won't work. Any idea how to resolve it ?

Upvotes: 0

Views: 348

Answers (2)

rushabhpathak
rushabhpathak

Reputation: 191

You can use "All in One Migration" Plugin from which you can export entire Website data and then install Wordpress and the same plugin in another domain or in localhost and there you can import the data. Go to the following link : https://wordpress.org/plugins/all-in-one-wp-migration/

Upvotes: 0

Vineet Kumar Singh
Vineet Kumar Singh

Reputation: 129

Let me explain to you the simple process when you transfer the wordpress website from an old domain to new domain. First of all upload all the files and in wp-config.php, change the db name, username, password and in some case db host too.

Now, go to the database and import the database of the old domain as it is.

After that you need to change the old domain to new domain. For that, you need to execute following four queries in the database.

UPDATE wp_options SET option_value = replace(option_value, 'http://olddomain.com', 'http://newdomain.com') WHERE option_name = 'home' OR option_name = 'siteurl';

UPDATE wp_posts SET guid = replace(guid, 'http://olddomain.com','http://newdomain.com');

UPDATE wp_posts SET post_content = replace(post_content, 'http://olddomain.com', 'http://newdomain.com');

UPDATE wp_postmeta SET meta_value = replace(meta_value, 'http://olddomain.com', 'http://newdomain.com');

Now, login to the Dashboard, hover on settings and click on permalinks. Change the current permalinks settings. It is necessary to change the permalink.

If you have not followed this process, follow it and let me know if you still get the error.

Upvotes: 2

Related Questions