
內容簡介
新增遺漏的類別
新增遺漏的選單狀態。新增的類別包括:
current-page-parent 和 current_page_parent
current-page-ancestor 和 current_page_ancestor
current-menu-ancestor
current-menu-parent
以下情況會新增這些類別:
查看附件頁面時,會為任何父頁面和其選單祖先新增類別。
查看文章時,會為任何相關的分類選單項目及其選單祖先新增類別。
管理選單選擇狀態
允許您控制當查看站點的某些頁面時應該選擇(或取消選擇)哪些選單項目。您需要為選單項目新增類別才能使用此功能。
ecms-archive-{$post_type} - 在查看文章類型存檔頁面時選取選單項目。
ecms-single-{$post_type} - 在查看單個文章類型頁面時選取選單項目。
ecms-taxonomy-{$taxonomy} - 在查看税目存檔頁面時選取選單項目。
ecms-taxonomy-{$taxonomy}-term-{$term} - 在查看稅目分類存檔頁面時選取選單項目。
ecms-404 - 在查看 404 頁面時選取選單項目。
ecms-no-archive-{$post_type} - 在查看文章類型存檔頁面時取消選取選單項目。
ecms-no-single-{$post_type} - 在查看單個文章類型頁面時取消選取選單項目。
ecms-no-taxonomy-{$taxonomy} - 在查看税目存檔頁面時取消選取選單項目。
ecms-no-taxonomy-{$taxonomy}-term-{$term} - 在查看稅目分類存檔頁面時取消選取選單項目。
ecms-no-404 - 在查看 404 頁面時取消選取選單項目。
外掛標籤
開發者團隊
原文外掛簡介
Add missing classes
Adds missing classes for selected menu states. Classes added include:
current-page-parent and current_page_parent
current-page-ancestor and current_page_ancestor
current-menu-ancestor
current-menu-parent
The classes are added in the following scenarios:
When viewing an attachment page classes are added to any parent pages and their menu ancestors.
When viewing a post classes are added to any relevant taxonomy menu items and their manu ancestors.
Manage Menu Select States
Allows you to control which menu items should be selected (or deselected) when viewing certain pages of your site. You need to add classes to the menu items for this to work.
ecms-archive-{$post_type} – Select menu item when viewing a post type archive page.
ecms-single-{$post_type} – Select menu item when viewing a single post type page.
ecms-taxonomy-{$taxonomy} – Select menu item when viewing a taxonomy archive.
ecms-taxonomy-{$taxonomy}-term-{$term} – Select menu item when viewing a taxonomy term archive.
ecms-404 – Select menu item when viewing a 404 page.
ecms-no-archive-{$post_type} – Deselect menu item when viewing a post type archive page.
ecms-no-single-{$post_type} – Deselect menu item when viewing a single post type page.
ecms-no-taxonomy-{$taxonomy} – Deselect menu item when viewing a taxonomy archive.
ecms-no-taxonomy-{$taxonomy}-term-{$term} – Deselect menu item when viewing a taxonomy term archive.
ecms-no-404 – Deselect menu item when viewing a 404 page.
