WordPress. 如何将您的网站从一个域名移动到另一个
May 27, 2016
在本教程中,我们将学习如何移动你的 website from one domain to another.
-
登录你的WordPress Dashboard. Go to the Settings > General tab;
-
在盒子里 WordPress地址(URL):将地址更改为主要WordPress核心文件的新位置;
-
在盒子里 网站地址(URL):将地址更改到新位置, 它应该匹配WordPress(您的公共站点)地址(URL);
-
Click Save Changes;
Do not 现在试着打开/查看你的博客!
-
Move 你的WordPress核心文件到 新位置;
-
作为WordPress安装的一部分,您必须修改 wp-config.php 文件来定义访问您的 MySQL database;
-
要改变 wp-config.php 文件,您将需要以下信息:
-
Database Name (Database WordPress使用的名称);
-
Database Username 访问时使用的用户名 Database;
-
Database Password (用户名使用的密码访问 Database);
-
Database Host (你的主机名 Database Server);
-
Open wp-config.php 文件和更改 database 名称、主机名、用户名和密码:
定义(“DB_NAME”、“wrd_examplename”); 定义(“DB_USER”、“wrd_exampleuser”); 定义(' DB_PASSWORD ', ' 123456789 '); 定义(“DB_HOST”、“localhost”);
-
Login to previous database via phpMyAdmin tool and export the database (of the existing website). Save the ‘xxx.sql’ (where xxx 是你的名字吗 database)文件到你的硬盘;
-
打开下载的 ‘xxx.sql’ 文件与任何文本/php editor. 替换之前的所有实例 domain 用你的电流命名 domain name;
E.g: http://www.oldwebsite.com 应该改为 http://www.newwebsite.com;
-
将更改保存为 ‘xxx.sql’ file;
-
Login to new database via phpMyAdmin tool and import the exported database (‘xxx.sql’ 文件)到新创建的 database;
-
You can now 打开你的网站 on a new hosting/domain. 转移手续已完成.
注意:如果您正在使用 自定义设置后, go to the Dashboard > Settings > Permalinks panel and update 您的permallinks结构.
Existing image/media 链接上传 media 将参考旧文件夹,必须与新位置更新. 您可以使用搜索和替换工具,或者在您的 SQL database.
请随时查看下面的详细视频教程:
WordPress. 如何将您的网站从一个域名移动到另一个看看其中一些最好的 WordPress设计网站 创建自己的网络资源.