SHARE
TWEET

Untitled

a guest Aug 14th, 2019 54 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. SET @oldsite = 'URL', @newsite = 'URL';
  2.  
  3.  
  4. UPDATE wp_options SET option_value = replace(option_value, @oldsite,  @newsite) WHERE option_name = 'home' OR option_name = 'siteurl';
  5. UPDATE wp_posts SET guid = replace(guid,  @oldsite,@newsite);
  6. UPDATE wp_posts SET post_content = replace(post_content,  @oldsite, @newsite);
  7. UPDATE wp_postmeta SET meta_value = replace(meta_value, @oldsite,@newsite);
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
Not a member of Pastebin yet?
Sign Up, it unlocks many cool features!
 
Top