简体   繁体   English

WordPress的永久链接一页打开首页,而不是实际的页面

[英]Wordpress permalink one page opens Home instead of actual page

I have following weird problem in Wordpress using permalinks. 我在使用永久链接的Wordpress中遇到了奇怪的问题。 When I use the default setting for permalinks, everything works just fine. 当我对永久链接使用默认设置时,一切正常。 But I want to use the post name as permalink. 但我想使用帖子名称作为永久链接。 When using the post name, one link opens the home page instead of the actual page. 使用帖子名称时,一个链接将打开主页,而不是实际页面。

Manually changing the permalink in the page settings leads to a 404 Error. 手动更改页面设置中的永久链接会导致404错误。 I dont think this is the problem but the links form the pages have some similarites: 我不认为这是问题所在,但是页面链接构成了一些相似之处:

Home page: www.website.com/name1/ 主页:www.website.com/name1/

Site with problem: www.website.com/name1/index.php/name1/ 有问题的网站:www.website.com/name1/index.php/name1/

What makes it even worse: when i set the parent of the page to home, everything works. 更糟糕的是:当我将页面的父页面设置为首页时,一切正常。

Changing the permalink manually to another string worked in the end. 最后,将永久链接手动更改为另一个字符串。

Might be a bug from wordpress with same names. 可能是来自具有相同名称的wordpress的错误。

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

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