然后通过以下SQL语句来替换新旧域名:
UPDATE wp_options SET option_value = replace(option_value,'old.com','new.com'); UPDATE wp_posts SET post_content = replace(post_content,'old.com','new.com'); UPDATE wp_posts SET guid = replace(guid,'old.com','new.com'); UPDATE wp_posts SET post_excerpt = replace(post_excerpt,'old.com','new.com'); UPDATE wp_comments SET comment_author_url = replace(comment_author_url,'old.com','new.com'); UPDATE wp_postmeta SET meta_value = replace(meta_value,'old.com','new.com');