分层 WordPress 页面导航,所有永久链接都位于根目录中

发布于 2024-08-15 03:15:50 字数 305 浏览 1 评论 0原文

有没有一种方法可以为 Wordpress 静态页面提供分层导航,而不会让永久链接看起来像在文件夹中一样?即,我想要这样的导航结构:

+ Home
+ About
|- Me
|- My Dog

...带有这样的永久链接:/home、/about、/me、/my-dog。我能找到通过 WordPress 设置这样的导航的唯一方法是使辅助页面成为其上方页面的子页面,但这使得永久链接看起来像这样: /about/me, /about/my-dog

有没有方式(使用插件或其他方式)获取从根链接的所有页面永久链接?

Is there a way to have a hierarchical nav for Wordpress static pages without having the permalinks appear like they're in folders? I.e., I want nav structured like this:

+ Home
+ About
|- Me
|- My Dog

...with permalinks like these: /home, /about, /me, /my-dog. The only way I can find to set up navigation like this through Wordpress is to make the secondary pages children of the page above them, but this makes the permalinks look like this: /about/me, /about/my-dog

Is there any way (with a plugin or otherwise) to get all of the page permalinks linked from the root?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

oО清风挽发oО 2024-08-22 03:15:50

Wordpress 3.0 有一个内置的菜单创建器。无论“页面”部分中的页面结构如何,您都可以自定义导航的布局。

要解决您的问题,请将所有页面设为根页面,然后使用菜单创建器重新排列它们。

Wordpress 3.0 has a built-in menu creator. you can customize the layout of your navigation regardless of how the pages are structured in the "Pages" section.

To solve your issue, have all pages be root pages and then rearrange them using the menu creator.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文