前言介紹
- 這款 WordPress 外掛「WP-Waitlist」是 2014-05-04 上架。
- 目前有 10 個安裝啟用數。
- 上一次更新是 2014-05-05,距離現在已有 4017 天。超過一年沒更新,安裝要確認版本是否可用。以及後續維護問題!
- 外掛最低要求 WordPress 3.1 以上版本才可以安裝。
- 有 1 人給過評分。
- 還沒有人在論壇上發問,可能目前使用數不多,還沒有什麼大問題。
外掛協作開發者
meitar |
外掛標籤
developer | user lists | user management |
內容簡介
在任何文章中加入一個或多個「列表」。你的網站註冊用戶可以加入或離開此列表。列表可以用於任何目的(例如活動 RSVP、進行投票或調查等),並且可以輕鬆地添加到任何文章類型。可選擇地,列表可以有您定義的最大用戶數,超過此數字的任何用戶都會自動添加到一個「等候列表」中。
此外,此外掛還可以滿足插件開發人員在按照帖子管理用戶集時所需的功能。提供了一組簡單的公共函數,供其他已安裝插件的開發人員使用,以獲取有關列表本身以及其中列出的用戶的信息。
代碼示例
安裝並啟用此外掛後,可以按照以下方式在自己的插件項目中引用它:
/**
* Plugin Name: My plugin project
* Plugin URI: http://example.com/
* Description: Example plugin for playing with WP-Waitlist.
* Author: Me, myself, and I
* Version: 1.0
*/
class My_Plugin {
private $WP_Waitlist;
public function __construct () {
add_action('init', array($this, 'registerDepdencies'));
}
public function registerDepdencies () {
global $WP_Waitlist;
if (!$WP_Waitlist) {
// WP-Waitlist is not available, issue an error.
// WP-Waitlist 不可用,發布錯誤訊息
} else {
$this->$WP_Waitlist = $WP_Waitlist;
}
}
}
$My_Plugin = new My_Plugin();
此外,您可以在自己的插件中按照以下方式調用 WP-Waitlist 的函數:
public function myPluginLearnsAboutWaitlists ($post_id) {
// 獲取此文章的作者創建的所有列表的數組。
$lists = $this->WP_Waitlist->getListsForPost($post_id);
// 你可以遍歷附加到此帖子的所有列表。
foreach ($lists as $list_name) {
$list_properties = $this->WP_Waitlist->getListProperties($post_id, $list_name);
foreach ($list_properties as $property_name => $property_value) {
print "$property_name is $property_value
";
}
// 你也可以瞭解哪些用戶在列表上...
$user_ids = $this->WP_Waitlist->getListedUsers($post_id, $list_name);
foreach ($user_ids as $id) {
$this_wp_user = get_userdata($id); // $this_wp_user 現在是一個 WP_User 對象。
}
// ...以及哪些用戶已被加入等候列表(在列表達到容量後加入的用戶)。
$waitlisted_users = $this->WP_Waitlist->getWaitlistedUsers($post_id, $list_name);
// 你也可以獲取所有已添加到列表中的用戶排序後的數組。
$all_user_ids_on_list = $this->WP_Waitlist->getUsersOnList($post_id, $list_name);
}
}
使用此外掛的其他插件
您有沒有了解到使用 WP-Waitlist 的插件呢?請透過在支援論壇發文向我們反應 🙂
WordPress Volunteer Project Manager
維護此外掛是出於愛好。如果您喜歡,請考慮捐贈您使用該外掛過程中的費用。
原文外掛簡介
Add one or more “lists” to any post. Registered users of your site can then join or leave the list. Lists can be used for any purpose (event RSVPs, running polls or surveys, etc.) and can be unobtrusively added to any post type. Optionally, lists can have a maximum number of users on it that you define, after which any user who joins the list is automatically added to an overflow “waitlist.”
This plugin also serves the needs of plugin developers who are looking for a simple way to manage sets of users on a per-post basis. A simple set of public functions are exposed to other installed plugins that developers can use to get information about the lists themselves, and the users listed on them.
Code examples
After installing and activating this plugin, include it in your own plugin project as follows:
$WP_Waitlist = $WP_Waitlist;
}
}
}
$My_Plugin = new My_Plugin();
At that point, you can call WP-Waitlist’s functions in your own plugin as follows:
public function myPluginLearnsAboutWaitlists ($post_id) {
// Get an array of all lists that the author of this post created.
$lists = $this->WP_Waitlist->getListsForPost($post_id);
// You can iterate through the lists attached to this post.
foreach ($lists as $list_name) {
$list_properties = $this->WP_Waitlist->getListProperties($post_id, $list_name);
foreach ($list_properties as $property_name => $property_value) {
print "$property_name is $property_value
";
}
// You can also learn which users are on the list...
$user_ids = $this->WP_Waitlist->getListedUsers($post_id, $list_name);
foreach ($user_ids as $id) {
$this_wp_user = get_userdata($id); // $this_wp_user is now a WP_User object.
}
// ...and which users have been waitlisted (joined after the list reached capacity).
$waitlisted_users = $this->WP_Waitlist->getWaitlistedUsers($post_id, $list_name);
// You can also get an array all users who have added themselves to the list, sorted by date.
$all_user_ids_on_list = $this->WP_Waitlist->getUsersOnList($post_id, $list_name);
}
}
Plugins that use this one
Know of a plugin that’s using WP-Waitlist? Let us know by posting in the support forum. 🙂
WordPress Volunteer Project Manager
Maintaining this plugin is a labor of love. However, if you like it, please consider making a donation for your use of the plugin, purchasing one of Meitar’s web development books or, better yet, contributing directly to Meitar’s Cyberbusking fund. (Publishing royalties ain’t exactly the lucrative income it used to be, y’know?) Your support is appreciated!
各版本下載點
- 方法一:點下方版本號的連結下載 ZIP 檔案後,登入網站後台左側選單「外掛」的「安裝外掛」,然後選擇上方的「上傳外掛」,把下載回去的 ZIP 外掛打包檔案上傳上去安裝與啟用。
- 方法二:透過「安裝外掛」的畫面右方搜尋功能,搜尋外掛名稱「WP-Waitlist」來進行安裝。
(建議使用方法二,確保安裝的版本符合當前運作的 WordPress 環境。
延伸相關外掛(你可能也想知道)
Elementor Beta (Developer Edition) 》成為我們未來版本的一部分, 透過安裝 Developer Edition 外掛,Elementor使用者可以提前一窺未來功能。我們邀請你參與並測試我們的 Developer Edition。這樣...。
P3 (Plugin Performance Profiler) 》這個外掛程式可以創建您 WordPress 網站的外掛程式效能概況,並且藉由測量這些外掛對網站載入時間的影響。通常WordPress網站由於過多或配置不佳的外掛程式而...。
FakerPress 》當您創建新的主題或外掛時,您總是需要創建自訂數據以測試您的外掛是否正常運作,作為開發人員,我們自己也遇到過這個問題。, 我們這個外掛的目標是填補這個...。
Maintenance Mode 》這個外掛主要是針對需要讓客戶在網站對外公開之前預覽網站,或是在 WordPress 網站進行重大更新時暫時隱藏網站的開發者。 , 任何具有 WordPress 管理員權限的...。
Debug Log Manager 》Debug Log Manager 可以讓您:, , 單擊啟用 WP_DEBUG 以記錄 PHP、數據庫和 JavaScript 錯誤,不需要手動編輯 wp-config.php 文件,完成後再禁用。 , 在自訂...。
Debug This 》Debug This是由友好Macho Themes團隊打造、維護和運營的獨立外掛程式。, 對於管理員、開發人員和支援人員,Debug This提供了大量的有關WordPress安裝的信息,...。
Debug Log – Manager Tool 》這是一個簡單的除錯日誌外掛程式,您可以在儀表板中檢查除錯日誌。透過一個點擊,您可以啟用或停用除錯功能(例如 ‘ WP_DEBUG’、‘WP_DEBUG...。
ReactPress – Create React App for WordPress 》ReactPress 讓你可以輕鬆地創建、構建和部署 React 應用程序到現有的 WordPress 網站。使用你的 React 知識為你的 WordPress 客戶創建單頁應用程序。, 只需幾...。
Developer 》一個能幫助 WordPress 開發者進行開發的外掛。, 這個外掛將幫助您優化您的開發環境,確保您已安裝所有必要的工具和外掛。, 如果您想查看代碼並做出貢獻,加入...。
Debug Bar Console 》在除錯列中新增了一個PHP/MySQL控制台。需要 Debug Bar 插件 (v0.5或更新版本)。。
System Dashboard 》這個外掛提供了一個中央儀表板,用於監視各種 WordPress 組件、進程和數據,包括伺服器硬體、軟體和資源使用情況。與 Query Monitor 和 WP Console 配對使用...。
Theme Inspector 》這個輕量級的外掛提供在開發 WordPress Classic 主題時可以使用的有用技術資訊,並在頁面和文章上顯示這些資訊。它提供簡單的訪問,例如文章/頁面 ID、slug、...。
Term Menu Order 》這個外掛旨在幫助主題和外掛開發人員。, 該外掛的目的是允許任意的詞彙排序,類似於頁面。這可以讓檢索詞彙的查詢使用 ‘menu_order’ 作為排序順...。
Ray 》Ray 是一款美觀、輕量的桌面應用程式,可幫助您進行應用程式的偵錯操作。可使用免費試用版,也可透過許可證進行解鎖。, 安裝此外掛後,您可以使用 ray() 函數...。
Bulk Content Creator 》作為 WordPress 開發人員,您可能想要快速創建多個帖子。使用批量內容創建器,您可以從單一界面創建多個帖子、頁面或其他自定義帖子類型。您還可以為帖子類型...。