简体   繁体   English

文件将一个域上载到另一个域,但是菜单不起作用

[英]Files uploaded one domain to another domain but menu not working

I have configured a site using WP on my Development Server and now I have moved it to another server with new URL. 我已经在开发服务器上使用WP配置了一个站点,现在将其移至具有新URL的另一台服务器。 I have changed URL in database as well. 我也更改了数据库中的URL。 But, my menus are pointing to the OLD URL and I am getting a 404 error. 但是,我的菜单指向OLD URL,但出现404错误。

How can I change them? 如何更改它们?

Try to use some wordpress plugins to migrate your website between servers. 尝试使用一些wordpress插件在服务器之间迁移您的网站。

Duplicator is one of them. 复制器就是其中之一。

https://wordpress.org/plugins/duplicator/ https://wordpress.org/plugins/duplicator/

You will have to do minimum effort if you use some tools. 如果您使用某些工具,则将需要做最少的工作。

Make SQL dump, overwrite old domain, load dump. 使SQL转储,覆盖旧域,加载转储。

Also checks configuration files & themes. 还检查配置文件和主题。

You probably forget some links in your database. 您可能会忘记数据库中的某些链接。 Check the following fields: 检查以下字段:

In wp_options , options with the following option_name : wp_options ,具有以下option_name选项:

siteurl , home siteurlhome

In wp_posts : wp_posts

Check all the guid values. 检查所有的guid值。

You need also to check that your .htaccess is using the correct RewriteBase . 您还需要检查.htaccess是否使用了正确的RewriteBase

If your menus are built from a special theme feature (not the default WP menu functionality), you may have some encoded string in wp_options that reflect the menu settings. 如果您的菜单是基于特殊主题功能(不是默认的WP菜单功能) wp_options ,则wp_options中可能有一些反映菜单设置的编码字符串。 If so check on this procedure . 如果是这样, 请检查此过程

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM