一、确保域名可以解析到对应服务器;
二、在phpMyAdmin找到数据库之后,点击SQL,执行以下语句:
UPDATE wp_options SET option_value = replace(option_value, ‘填写旧域名‘,’填写新域名‘) ;
UPDATE wp_posts SET post_content = replace(post_content, ‘填写旧域名‘,’填写新域名‘) ;
UPDATE wp_comments SET comment_content = replace(comment_content, ‘填写旧域名‘, ‘填写新域名‘) ;
UPDATE wp_comments SET comment_author_url = replace(comment_author_url, ‘填写旧域名‘, ‘填写新域名‘) ;