[WordPress] 外掛分享: Auto Submenu

首頁外掛目錄 › Auto Submenu
2,000+
安裝啟用
★★★★
4/5 分(25 則評價)
106 天前
最後更新
問題解決
WordPress 5.4+ PHP 7.4+ v1.0.5 上架:2012-04-25

內容簡介

WordPress 的預設選單系統只允許您「自動添加新的一級頁面」,對於新的子頁面沒有提供相同的功能。Auto Submenu 解決了這個問題。

啟用後,每當您發佈新的子頁面時,Auto Submenu 將自動添加到與其父頁面位於同一個自訂選單的位置(在其父頁面下一個層級)。如果您希望重新排序或從菜單中刪除新頁面,則可以在管理選單畫面中輕鬆進行操作。

插件沒有任何設置。Auto Submenu 將為啟用「自動添加新的一級頁面」設置的所有自訂選單提供服務。

外掛標籤

開發者團隊

⬇ 下載最新版 (v1.0.5) 或搜尋安裝

① 下載 ZIP → 後台「外掛 › 安裝外掛 › 上傳外掛」
② 後台搜尋「Auto Submenu」→ 直接安裝(推薦)
📦 歷史版本下載

原文外掛簡介

The default custom menu in WordPress only allows checking the “Automatically add new top-level pages” (Appearance > Menus) or adding a Navigation block with all pages and all child pages (Appearance > Editor).
With Auto Submenu you get extra functionality to automatically include child pages into the menu.
NEW: ASM now provides support for the Customizer via Appearance > Customize
NEW: ASM now provides support for Full Site Editing with the Gutenberg Block Editor via Appearance > Editor
Using it
Enable the plugin and go to Appearance > Editor.
For each Page in your menu, you now have the following extra configuration options:

Add child pages as submenu y/n;
child pages are ordered ascending by Menu Order;
specify the (maximum) nesting depth of children you want to show (max 3);
specify the title for the child pages. For this you can use %post_title, %post_author and other wildcards, see ‘Other Notes > Wildcards’. Default value: %post_title

Via Appearance > Menus and Appearance > Customize you also get the following option:

Check the “Automatically add new top-level and all its child pages to this menu (Auto Submenu)”-checkbox.
If this option is checked, all top-level pages will automatically be added and will automatically have all child pages added as submenu.

With the Free version you cannot control the nesting depth of the child pages, all subpages are added, regardless the depth of the page tree.
Wildcards
You can control the title of the menu items generated by the plug-in with the following wildcards:

%post_title
%post_author
%post_date for the unformatted post date: 2012-11-10 18:14:23
%post_date() for a formatted post date with the following default formatting: November 10th, 2012
%post_date() for custom date formatting. Example: %post_date(l jS \of F Y, h:i:s A). See https://codex.wordpress.org/Formatting_Date_and_Time for formatting options.
%post_date_gmt
%post_date_gmt()
%post_date_gmt()

延伸相關外掛

文章
Filter
Mastodon