Skip to content

Instantly share code, notes, and snippets.

@jpcontrerasv
Created July 30, 2014 14:53
Show Gist options
  • Save jpcontrerasv/7ae100f088eb155a8c47 to your computer and use it in GitHub Desktop.
Save jpcontrerasv/7ae100f088eb155a8c47 to your computer and use it in GitHub Desktop.
Reemplazos base de datos
UPDATE wp_options SET option_value = replace(option_value, 'http://www.oldsiteurl.com', 'http://www.newsiteurl.com') WHERE option_name = 'home' OR option_name = 'siteurl';
UPDATE wp_posts SET guid = REPLACE (guid, 'http://www.oldsiteurl.com', 'http://www.newsiteurl.com');
UPDATE wp_posts SET post_content = REPLACE (post_content, 'http://www.oldsiteurl.com', 'http://www.newsiteurl.com');
http://www.onextrapixel.com/2010/01/30/13-useful-wordpress-sql-queries-you-wish-you-knew-earlier/
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment