[WordPress] 外掛分享: XMPP Enabled

首頁外掛目錄 › XMPP Enabled
⚠ 此外掛已下架 — 不再更新維護,建議勿安裝。
10+
安裝啟用
★★★★★
5/5 分(1 則評價)
3024 天前
最後更新
問題解決
WordPress 3.0+ v1.0.2 上架:2010-04-27

內容簡介

XMPP Enabled 提供一個給其他插件使用 Jabber/XMPP 協議的單一功能 API。
如果您想在通知中使用 XMPP 協議,請參閱 API 部分以獲取詳細信息。

GitHub 頁面:https://github.com/sandfoxme/xmpp-enabled

感謝

Mako N(日語翻譯和 i18n 支援)

插件 API
單一功能

發送 XMPP 消息的單一功能為 xmpp_enabled。它可以直接從任何 WordPress 插件中調用

xmpp_enabled($recipient, $message, $subject='', $type='normal');

$recipient 是收件人的有效(裸或完整)JID,如 ‘[email protected]
$message 是要發送的純文本消息
$subject 是消息的標題行。對於聊天類型的消息,通常省略
$type 是消息的類型。它可以是 ‘chat’、‘normal’ 或 ‘headline’。有關詳細信息,請參閱RFC 3921

例如:xmpp_send('[email protected]',"讀取我們的新文章:\nhttp://something.com/new-post",'新文章已發布','headline');

在 XMPP Enabled 部分中創建子菜單

XMPP Enabled 創建了自己的部分,您可以自由地在其中使用它為您的插件。代碼為 'xmpp-enabled'

例如:add_submenu_page('xmpp-enabled', 'Jabber Comment Notifications', 'Comment Notifications', 'administrator', __FILE__, 'jcommnotify_settings');

有關詳細信息,請參閱 WordPress Codex 中的添加管理菜單。

外掛標籤

開發者團隊

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

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

原文外掛簡介

XMPP Enabled provides a single function API for other plugins that use Jabber/XMPP messaging protocol.
See API section for details if you want to use XMPP protocol in your notifications.

GitHub page: https://github.com/sandfoxme/xmpp-enabled

Thanks to

Mako N (Japanese translation and i18n support)

Plugin API
The Single Function
The single function for sending XMPP Messages is xmpp_enabled. It can be called directly from any WordPress plugin
xmpp_enabled($recipient, $message, $subject='', $type='normal');

$recipient is a valid (bare or full) JID of the recipient like ‘[email protected]
$message is a plain text message to be sent
$subject is a title line for message. It is usually omitted for chat-type messages
$type is a type of message. It can be ‘chat’, ‘normal’ or ‘headline’. See RFC 3921 for details

Example: xmpp_send('[email protected]',"Read our new post:\nhttp://something.com/new-post",'New post is published','headline');
Create submenu in the XMPP Enabled section
XMPP Enabled creates it’s own section and you’re free to use it for your plugins. The code is 'xmpp-enabled'
Example: add_submenu_page('xmpp-enabled', 'Jabber Comment Notifications', 'Comment Notifications', 'administrator', __FILE__, 'jcommnotify_settings');
See Adding Administration Menus in WordPress Codex for further details

延伸相關外掛

文章
Filter
Mastodon