网站中字preSS重定向到迁移后,旧的URL [英] Website in wordpress redirects to old URL after migration

查看:132
本文介绍了网站中字preSS重定向到迁移后,旧的URL的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我从来没有做过迁移网站上字preSS,我会把一步一步怎么做,需要把网站上的一个新的领域是在同一台服务器上,所以只迁移的文件,该数据库是相等的。

I had never done migrating a site on wordpress, I'll put step by step how I did, need to put the site on a new domain that are on the same server, so only the migrated files, the database is equal.

我复制从旧词preSS的所有文件到新的站点文件夹, 我对新的网站结果如下: 首页 - 该网站进行的主题,但出现一则消息:404:网页或文件未找到。 newsite /可湿性粉剂管理员/ - 重定向到oldsite /可湿性粉剂管理员/

I copied all the files from the old wordpress to the new site folder, I had the following result on the new site: Home - The site carries the theme but a message appears: 404: PAGE OR FILE NOT FOUND. newsite/wp-admin/ - redirect to oldsite/wp-admin/

我在网站管理员老把新的URL的选项,但我恐怕永远无法访问。它可以去吗?

I have the option in the site administrator old put the new URL but I'm afraid I could never access. it can go?

感谢。

推荐答案

您需要作出改变你的数据库。 在数据库表wp_options(或任何数据库preFIX是),你需要改变两行。

You need to make a change to your database. In the database table wp_options (or whatever your database prefix is), you need to change two lines.

每个人都应该是 option_id 1,的option_name SITEURL。更改请将option_value 从旧的URL到新的URL。

One should be option_id 1, option_name siteurl. Change the option_value from the old url to the new url.

同样也应该有 option_id 36,的option_name 回家。更改请将option_value 也从旧的URL到新的URL。

Similarly there should also be option_id 36, option_name home. Change the option_value also from the old url to the new url.

这应该做的伎俩。还检查了<一href="http://wp.smashingmagazine.com/2013/04/08/moving-word$p$pss-website/">http://wp.smashingmagazine.com/2013/04/08/moving-word$p$pss-website/最好的方法来移植。

This should do the trick. Also check out http://wp.smashingmagazine.com/2013/04/08/moving-wordpress-website/ for the best method to migrate.

修改

在评论达蒙还提到了问题再联的所有图像。这肯定可以是一个正确的痛苦,但我认为这个插件。

In the comments Damon also mentions the issue with re-linking all the images. This for sure can be a right pain, but I suggest this plugin.

<一个href="http://word$p$pss.org/plugins/search-and-replace/">http://word$p$pss.org/plugins/search-and-replace/

只要搜索旧的URL,然后换上新的。在此之前,虽然,请确保您有数据库的备份。您可以使用插件来惹你的数据库从来没有保证的结果。但是,这一直为我工作。

Just search for the old url and replace with the new one. Before doing this though, make sure you have a backup of the database. You can never guarantee the results when using plugins to mess with your database. But this has always worked for me.

这篇关于网站中字preSS重定向到迁移后,旧的URL的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆