Change your WordPress Links

I recently changed my host provider. Afterwards my wordpress blog got a new domain (at last with https) and a new url. Unfortunately, WordPress works with absolute links. All my image and other links went still to the old url. You find a lot of tipps how to change your with SQL or with plugin. Alas, I didn’t want to install another plugin. The SQL wasn’t an option either, as wordpress has more than 20 tables and you have to make the changes separately for each table and each field where the url could occur.

I found a simpler and less tedious way: The Plesk Control Panel is offering in the menu “Databases” the option to export and import database dumps.

Exporting and importing database dumps in Plesk

A database dump of a MySQL-database is a very large sql textfile. You just unzip the SQL file, open it in your favourite text editor (mine is Notepad++), search and replace all the Urls, save the changed textfile and reimport the dump file. This worked like a charm! And it was worth the effort, my text editor made more than 30’000 replacements! I recommend to keep the original dump at least until you successfully uploaded the revised dump file. If anything goes wrong, you can go back to the previous version.

Comments are closed.