前言介紹
- 這款 WordPress 外掛「Context Manager」是 2012-12-14 上架。
- 目前有 30 個安裝啟用數。
- 上一次更新是 2013-11-13,距離現在已有 4190 天。超過一年沒更新,安裝要確認版本是否可用。以及後續維護問題!
- 外掛最低要求 WordPress 3.2 以上版本才可以安裝。
- 有 5 人給過評分。
- 還沒有人在論壇上發問,可能目前使用數不多,還沒有什麼大問題。
外掛協作開發者
外掛標籤
rules | context | widget logic | wp_enqueue_styles | wp_enqueue_scripts |
內容簡介
Context Manager 讓您的網站根據當前用戶的上下文而表現出不同的行為。使用簡單的拖放管理頁面,您的網站有以下四種不同的反應方式:
包括或排除 CSS 和 JavaScript 文件
更改菜單項目的行為
隱藏側邊欄中的小部件
新增額外的類別至
插件取代了菜單規則
範例使用方法
一個網站具有由自定文章類型「產品」驅動的電子商務購物功能。有一個名為「店鋪」的檔案頁列出了產品並連結在主導覽菜單中。
使用者訪問「店鋪」,菜單項目變成「活躍」,但當他們點選個別產品時,菜單項目失去其狀態。使用者感到迷失。
安裝 Context Manager 插件
新增一個 context 規則
在標題欄位輸入有意義的名稱。這只是用於管理目的的
在條件欄位中輸入 is_singular( 'product' )
選擇作為菜單規則的「仿造現行頁面以子項目的身份,但不建立菜單項目」
在菜單下拉選單中找到您的產品頁面
在產品頁面上,有一些無關緊要的小部件會分散使用者購買的注意力。
在小部件反應下隱藏無關緊要的小部件
整個店鋪部分需要其自己的配色方案,但沒有一個共同的類別將所有頁面串連在一起。
在 body class 的反應中輸入「shop-section」類別名稱。或者,使用wp_register_style() 在您的佈景主題的 functions.php 中註冊另一個樣式表。
建立
當您準備好儲存時,請記得點選發佈。
觀看屏幕截圖來查看以上設置的效果。
支援
如果您有問題,可以在Twitter上向我尋求幫助。
原文外掛簡介
Context Manager makes your site behave differently depending on the current user’s context. Using the simple point-and-click admin pages, there are four different ways your site can react:
Include and exclude CSS and JavaScript files
Changing the behaviour of menu items
Hiding widgets in sidebars
Adding extra classes to the
The plugin supersedes Menu Rules
Example usage
A website has e-commerce shopping functionality driven by a custom post type called ‘products’. There’s an archive page called ‘shop’ that lists products and is linked to in the main navigation menu.
A user visits ‘shop’ and the menu item becomes ‘active’, but when they click through to an individual product, the menu item loses its state. The user becomes lost.
Install the Context Manager plugin
Add a new context rule
Give it a meaningful name in the title field. This is just for administration purposes
In the conditions field enter is_singular( 'product' )
Choose Emulate current page as a child but do not create a menu item. as the menu rule
Find your products page in the menu dropdown
On the product page, there are irrelevant widgets that distract the user from making a purchase.
Hide irrelevant widgets under the widgets reaction
The whole shop section requires its own colour scheme, but there’s no common class that ties all the pages together.
Enter shop-section class name in the body class reaction. Or alternatively, register another stylesheet using wp_register_style() in you theme’s functions.php.
Create
Remember to click publish when you’re ready to save.
Have a look at screenshots to see the above setup in action.
Support
If you’re stuck, ask me for help on Twitter.
各版本下載點
- 方法一:點下方版本號的連結下載 ZIP 檔案後,登入網站後台左側選單「外掛」的「安裝外掛」,然後選擇上方的「上傳外掛」,把下載回去的 ZIP 外掛打包檔案上傳上去安裝與啟用。
- 方法二:透過「安裝外掛」的畫面右方搜尋功能,搜尋外掛名稱「Context Manager」來進行安裝。
(建議使用方法二,確保安裝的版本符合當前運作的 WordPress 環境。
1.0 | 1.1 | 1.0.1 | 1.0.2 | 1.1.1 | 1.1.2 | 1.1.3 | 1.1.4 | 1.1.5 | 1.2.0 | trunk |
延伸相關外掛(你可能也想知道)
ThemeZee Toolkit 》ThemeZee Toolkit 是一款很實用的插件,內含多個小型模組和功能,方便地打包在一起。該插件專為 ThemeZee WordPress 主題設計,但也適用於其他主題。, 內含功...。
Hide Widgets (SP Display Widgets) 》此外掛可隱藏指定頁面上的小工具,並為每個小工具新增複選框,以便在每個網站頁面上顯示或隱藏它。。
Warm Welcome 》在幾分鐘內為您的網站創建視頻消息, 您可以創建個性化的視頻錄音以吸引用戶,或在頁角顯示的頁面泡泡。, 請造訪 https://warmwelcome.com 以獲取更多信息。, ...。
Visitor Logic Lite 》Visitor Logic Lite 是一款功能強大的 WP 外掛,允許網站管理員對其網站上的內容或媒體應用"邏輯"。, 與高價的開發人員定制這些元素不同,使用 Visitor Logic...。