[WordPress] 外掛分享: Visibility Control for LearnDash

WordPress 外掛 Visibility Control for LearnDash 的封面圖片。

前言介紹

  • 這款 WordPress 外掛「Visibility Control for LearnDash」是 2019-08-27 上架。
  • 目前有 1000 個安裝啟用數。
  • 上一次更新是 2025-04-21,距離現在已有 12 天。
  • 外掛最低要求 WordPress 4.0 以上版本才可以安裝。
  • 外掛要求網站主機運作至少需要 PHP 版本 5.6 以上。
  • 有 9 人給過評分。
  • 還沒有人在論壇上發問,可能目前使用數不多,還沒有什麼大問題。

外掛協作開發者

liveaspankaj |

外掛標籤

lms | hide | elearning | learndash | hide content |

內容簡介

Visibility Control for LearnDash 可協助您隱藏 WordPress 頁面上特定準則的訊息和內容。

您可以基於以下條件,顯示/隱藏 HTML 元素、選單和其他細節:

1. 使用者訪問特定、所有或所有 LearnDash 課程,或
2. 使用者訪問特定、所有或所有 LearnDash 群組,或
3. 使用者已登入或已登出。
4. 使用者角色。

您只需要為元素 div 或 span 添加 CSS 類別。如下所述:

範例:

登入/登出狀態:

- 若要向已登入的使用者顯示元素/選單項目,請添加此 CSS 類別:visible_to_logged_in 或 hidden_to_logged_out。
- 若要從已登入的使用者隱藏元素/選單項目,請添加此 CSS 類別:visible_to_logged_out 或 hidden_to_logged_in。

使用者角色:

- 若要向管理員顯示元素/選單項目,請添加此 CSS 類別:visible_to_role_administrator 或 hidden_to_role_administrator。
- 注意:要僅向多個特定角色顯示元素,您需要為每個角色添加元素。要從特定多個角色隱藏元素/選單,您可以為同一元素添加多個類別。

所有課程:

- 若要向訪問所有課程的使用者顯示元素/選單項目,請添加此 CSS 類別:visible_to_course_all。
- 若要從訪問所有課程的使用者隱藏元素/選單項目,請添加此 CSS 類別:hidden_to_course_all。
- 若要向未註冊任何課程的使用者顯示元素/選單項目,請添加此 CSS 類別:visible_to_course_none。
- 若要從未註冊任何課程的使用者隱藏元素/選單項目,請添加此 CSS 類別:hidden_to_course_none。

特定課程(如果課程 ID 為 123):

- 若要向訪問上述課程的使用者顯示元素/選單項目,請添加此 CSS 類別:visible_to_course_123。
- 若要從訪問上述課程的使用者隱藏元素/選單項目,請添加此 CSS 類別:hidden_to_course_123。

訪問至少一個課程的使用者:

- 添加此 CSS 類別:hidden_to_course_none。

所有群組:

- 若要向訪問所有群組的使用者顯示元素/選單項目,請添加此 CSS 類別:visible_to_group_all。
- 若要從訪問所有群組的使用者隱藏元素/選單項目,請添加此 CSS 類別:hidden_to_group_all。
- 若要向未加入任何群組的使用者顯示元素/選單項目,請添加此 CSS 類別:visible_to_group_none。
- 若要從未加入任何群組的使用者隱藏元素/選單項目,請添加此 CSS 類別:hidden_to_group_none。

特定群組(如果群組 ID 為 123):

- 若要向訪問上述群組的使用者顯示元素/選單項目,請添加此 CSS 類別:visible_to_group_123。
- 若要從訪問上述群組的使用者隱藏元素/選單項目,請添加此 CSS 類別:hidden_to_group_123。

訪問至少一個群組的使用者:

- 添加此 CSS 類別:hidden_to_group_none。

運作機制:

- 多個可見度控制類別:如果添加了多個可見度控制類別,必須滿足所有條件才能保持元素可見。如果其中任何一個隱藏元素,它將被隱藏。例如:visible_to_group_123 visible_to_group_124 只會向那些兩個群組都有存取權限的使用者顯示元素。
- 隱藏的內容/元素會到達瀏覽器。雖然使用者看不到它。
- CSS 被添加到所有需要的 CSS 元素的頁面中。

原文外掛簡介

Visibility Control for LearnDash helps you hide messages and content for specific criterion anywhere on your WordPress page.
You can show/hide HTML elements, menus, and other details based on:
1. User’s access to a particular, any or all LearnDash Course, Or
2. User’s access to a particular, any or all LearnDash Group, Or
3. User is Logged In or Logged Out.
4. User’s role.
You simply need to add a CSS class to your element div or span. As explained here:
Example:
Login/Logout Status:

To show the element/menu item to a logged-in user, add this CSS class: visible_to_logged_in OR hidden_to_logged_out
To hide the element/menu item from a logged-in user, add this CSS class: visible_to_logged_out OR hidden_to_logged_in

For user’s role:
* To show the element/menu item to a user will role administrator, add this CSS class: visible_to_role_administrator OR hidden_to_role_administrator
* Note: To show an element to multiple specific roles only, you need add the element multiple times, one for each role. To hide an element/menu from specific multiple roles only you can add the element once add multiple classes to the same element.
For all the courses:

To show the element/menu item to user with access to all the Courses, add this CSS class: visible_to_course_all
To hide the element/menu item from user with access to all the Courses, add this CSS class: hidden_to_course_all
To show the element/menu item to users not enrolled in any Course, add this CSS class: visible_to_course_none
To hide the element/menu item from users not enrolled in any Course, add this CSS class: hidden_to_course_none

For a specific course, if Course ID is 123:

To show the element/menu item to user with access to above Course, add this CSS class: visible_to_course_123
To hide the element/menu item from user with access to above Course, add this CSS class: hidden_to_course_123

For users with access to at least one course:
* Add this CSS class: hidden_to_course_none
For a course completion status, if Course ID is 123:

To show the element/menu item to user who completed above course, add this CSS class: visible_to_course_complete_123
To hide the element/menu item from user who completed above course, add this CSS class: hidden_to_course_complete_123
To show the element/menu item to user who has not completed above course, add this CSS class: visible_to_course_incomplete_123
To hide the element/menu item from user who has not completed above course, add this CSS class: hidden_to_course_incomplete_123

For all the groups:

To show the element/menu item to user with access to all the groups, add this CSS class: visible_to_group_all
To hide the element/menu item from user with access to all the groups, add this CSS class: hidden_to_group_all
To show the element/menu item to users not enrolled in any group, add this CSS class: visible_to_group_none
To hide the element/menu item from users not enrolled in any group, add this CSS class: hidden_to_group_none

For a specific group, if Group ID is 123:

To show the element/menu item to user with access to above Group, add this CSS class: visible_to_group_123
To hide the element/menu item from user with access to above Group, add this CSS class: hidden_to_group_123

For users with access to at least one group:
* Add this CSS class: hidden_to_group_none
Mechanism of Functioning

Multiple CSS Classes: If multiple visibility control classes are added, ALL of them must meet the criterion to keep the element visible. If any one of them hides the element, it will be hidden. For example: visible_to_group_123 visible_to_group_124 will show the element only to those who have access to both groups.
Hidden data/elements reaches the browser. Though user’s do not see it.
CSS is added to the page for all CSS elements that needs to be hidden based on above rules.
After page is loaded. These elements are removed from page using jQuery (if available), so it won’t be available even on Inspect.
Elements rendered after the page load are hidden but not removed from DOM/page.

Future Development
Depending on the interest in this feature, we will decide on adding a shortcode and/or a Gutenberg Block to achieve this feature.
Other Visibility Control Plugins:
– Visibility Control for LearnDash LMS
– Visibility Control for WP Courseware LMS
– Visibility Control for LearnPress LMS
– Visibility Control for LifterLMS
– Visibility Control for TutorLMS
– Visibility Control for MasterStudyLMS
– Visibility Control for Sensei LMS
– Visibility Control for WooCommerce
Related Plugins for LearnDash LMS:
* Manual Completions for LearnDash LMS
* Manage Enrollment for LearnDash LMS
* Autocomplete LearnDash Lessons and Topics
It is pretty similar to this plugin and having same features, it allows controlling the visibility of HTML elements based user’s purchase of a particular WooCommerce Product or Variation.

各版本下載點

  • 方法一:點下方版本號的連結下載 ZIP 檔案後,登入網站後台左側選單「外掛」的「安裝外掛」,然後選擇上方的「上傳外掛」,把下載回去的 ZIP 外掛打包檔案上傳上去安裝與啟用。
  • 方法二:透過「安裝外掛」的畫面右方搜尋功能,搜尋外掛名稱「Visibility Control for LearnDash」來進行安裝。

(建議使用方法二,確保安裝的版本符合當前運作的 WordPress 環境。


最新版本

延伸相關外掛(你可能也想知道)

  • Uncanny Automator – Easy Automation, Integration, Webhooks & Workflow Builder Plugin 》Uncanny Automator 是一個無需編程最簡單且最強大的自動化 WordPress 外掛。使用數十億種配方組合,能在幾分鐘內建立自動化連接 WordPress 插件、網站和應用...。
  • Uncanny Toolkit for LearnDash 》重要提示:本外掛需要 PHP 版本 7.2 或以上和 LearnDash 版本 3.6 或以上。, Uncanny Toolkit for LearnDash 外掛新增了 16 種模塊,包括登入表單、登入重新...。
  • Design Upgrade for LearnDash 》LearnDash 是一款強大的學習管理系統 (LMS),用於管理線上課程,但有些地方的設計還是有所不足,為了提供您的學生非凡的學習體驗,您需要一個專業的設計。, ...。
  • GamiPress – LearnDash integration 》完成學習通(LearnDash)網站的「遊戲化(Gamify)」,感謝強大的WordPress外掛:GamiPress!, , 該外掛自動連接GamiPress和LearnDash並新增活動事件。, , 新增的...。
  • LearnDash LMS – Reports 》使用最全面的洞察力來學習LearnDash報告儀表板, , 用我們智能新插件 WISDM Reports for LearnDash 輕鬆解讀您的課程數據,它通過圖形報告提供詳細的學習者表...。
  • BuddyPress for LearnDash 》想讓您的學習者互動嗎?BuddyPress for LearnDash將您的課程驅動網站轉變為一個社交教育平台,創造了BuddyPress和LearnDash之間的無縫連接。, BuddyPress群組...。
  • PowerPack for LearnDash 》PowerPack for LearnDash 外掛可讓你在不需要程式碼的情況下控制 LearnDash 網站的多個方面!讓你的 LearnDash 網站更強大。其中包括 42 個模組,包括:, , ...。
  • Autocomplete LearnDash Lessons and Topics 》LearnDash課程和主題自動完成自動完成教訓和主題。, 以下是其運作方式:, * 首次訪問學生可以看到“完成標記”按鈕。, * 他們可以使用該按鈕轉到下一課程。, * ...。
  • Easy Dash for LearnDash 》為 LearnDash 網站改進並提供簡易的儀表板。, 主要功能(免費版本):, , 所有內容均在一個頁面中, 學生、組別、評論、課程、課程、主題、測驗的數量, 課程報...。
  • Widget Areas for LearnDash 》Widget Areas for LearnDash 是一款外掛,可以在 LearnDash 之中新增多個小工具區塊 (也稱為「側邊欄」) 以供客製化學習體驗。透過建構在 LearnDash 內建的回...。
  • Manage Enrollment for LearnDash 》Manage Enrollment for LearnDash 可以讓您批量為用戶註冊課程或群組。您可以從指定的使用者介面中選擇用戶,貼上用戶清單,或使用 CSV 批量上傳您選擇的課程...。
  • Topic Progression Using Storyline/Captivate for LearnDash 》, 如果你的 eLearning 作者工具是 Articulate Storyline 或 Adobe Captivate,你會知道你可以將你的數位內容嵌入 LearnDash LMS 主題頁面。, 但是,如果你不...。
  • BadgeOS LearnDash Add-on 》課程, , 「BadgeOS LearnDash Add-on」可讓學習者從 LearnDash 學習管理系統中的幾乎每一個課程、課程內容和測驗活動中獲得成就和徽章。啟用後,在編輯或建立...。
  • Dashboard Widgets for LearnDash 》LearnDash 控制面板小工具為 WordPress 主控台頁面新增了 4 個小工具:概覽、課程、鏈結和最近修改。, , LearnDash 概覽小工具會顯示課程、課程單元、主題、...。
  • myCred – Learndash 》myCred Learndash 是 WordPress 的外掛,可根據 Learndash 插件建立點數。此外掛能幫助使用者在完成課程、課程小節、主題或測驗時獲得點數。此外掛可以在Lear...。

文章
Filter
Apply Filters
Mastodon