WordPress problem when moving foldersFebruary 26, 2012 / by Marco / Categories : Technology
I tried moving my WordPress folder to the root of my hosting account and things went pear shaped. After some debugging, I noticed that in the database stored the URL of the website. This meant I had to change most of the data entries in the database. I knew nothing about SQL queries but after some research I managed to find some code that was able to change my domain URL and here it is:
1234567 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');
Limit to 5 sponsors.
OTHER ARTICLES YOU MAY LIKE
If you’ve logged into Gmail and you’re seeing icons on the left hand side menu sidebar instead of the typical names and folders, then you need to watch this fix. It is a very easy fix but it took me a while to figure it out: You simply need to click on the Main Menu […]read more
So I spent hours trying to resolve this and finally managed to land on the correct instructions and decided to share it with my readers. I use ZOHO MAIL for email hosting on some of my domain names and when I tried sending an email from one of the accounts, the FROM name was not […]read more