Moving Wordpress Domain

荒凉一梦 提交于 2019-12-12 04:00:03

问题


I can not believe that moving wordpress domain is so complicated.

I installed wordpress and setup an online shop using a theme based on woocommerce. After installing better-wp security plugin I bought a domain for my online shop. I point the domain name's DNS to my hosting and add the domain name to my hosting account

I then replace the database's url with the new domain using search and replace db plugin for wordpress.

then I go to wordpress admin setting - general and replace the site URL's sub directory path and wordpress home directory with the domain name.

but when I access my website now, all the link still point to the sub-directory's name for example: www.mywebsite.com/woocommerceshop and if I click it I get an error message: this webpage has a redirect loop err too many redirects

and all the icon's links are broken. Can someone help me to fix this and point me to tutorial on how to move wordpress domain


回答1:


The two resources that you need are those links:

https://codex.wordpress.org/Changing_The_Site_URL https://codex.wordpress.org/Moving_WordPress

The most important steps are:

  1. Change the siteurl and home in the wp_options table
  2. Run the query to change the domains the wp_posts table

UPDATE wp_posts SET post_content = REPLACE(post_content,'www.domain.com/wp-content/uploads','www.domain.com/images');

Maybe the plugin has missed something ...



来源:https://stackoverflow.com/questions/32021510/moving-wordpress-domain

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!