
語言 🇹🇼 繁體中文
🇺🇸
English
🇧🇬
Български
🇨🇳
简体中文
🇹🇼
繁體中文
🇭🇷
Hrvatski
🇩🇰
Dansk
🇳🇱
Nederlands
🇺🇸
English (US)
🇨🇦
Français (Canada)
🇫🇷
Français (France)
🇩🇪
Deutsch
🇨🇾
Ελληνικά (Κύπρος)
🇬🇷
Ελληνικά
🇮🇱
עברית
🇮🇹
Italiano
🇯🇵
日本語
🇰🇷
한국어
🇵🇱
Polski
🇧🇷
Português (Brasil)
🇷🇺
Русский
🇺🇦
Русский (Украина)
🇧🇦
Српски (БиХ)
🇷🇸
Srpski (Latinica)
🇲🇪
Српски (Црна Гора)
🇷🇸
Српски
🇸🇮
Slovenščina
🇪🇸
Español
🇺🇦
Українська
🇹🇷
Türkçe
快速開始
設定
文件
Add Comments to Your Drupal Site
這是 FastComments 的官方 Drupal 模組。
一個將 FastComments 與 Drupal 10/11 整合的 Drupal 模組,提供 widget 區塊、實體欄位整合、SSO(單一登入)以及細緻的權限控制。
儲存庫
安裝 
- 將此模組放在您 Drupal 網站的
modules/custom/fastcomments/目錄中(或透過 Composer 安裝:composer require drupal/fcom)。 - 啟用此模組:
或者透過管理介面在 擴充功能 (drush en fastcomments/admin/modules) 啟用。
設定 
前往 管理 > 設定 > 內容 > FastComments (/admin/config/content/fastcomments)。
設定
- 租戶 ID(必填) - 您的 FastComments 租戶 ID。可在 Settings > API/SSO(EU)找到。
- API 密鑰 - 用於安全 SSO、Webhooks 驗證與頁面同步。可在 Settings > API/SSO(EU)找到。
- SSO 模式 - 單一登入整合:
- None - 無 SSO,使用者以訪客身分留言或建立 FastComments 帳號。
- Simple - 將 Drupal 使用者資訊(姓名、電子郵件、大頭貼)傳給 FastComments,無伺服器端驗證。
- Secure - 使用 HMAC-SHA256 驗證以安全地讓 Drupal 使用者與 FastComments 驗證(建議)。
- 評論樣式 - 要顯示的元件類型:
- Live Comments - 即時串列回覆式評論。
- Streaming Chat - 即時聊天介面。
- Collab Chat - 在主要內容區進行協作文字選取註解。
- Collab Chat + Comments - 同時顯示協作聊天與標準評論。
- CDN URL - FastComments CDN URL(預設:
https://cdn.fastcomments.com)。 - Site URL - FastComments 網站 URL(預設:
https://fastcomments.com)。 - 電子郵件通知 - 當內容有新評論時,寄送電子郵件給內容作者。
將評論新增至內容類型
透過 Structure > Content types > [type] > Manage fields 將 FastComments 欄位新增到您的內容類型。此欄位具有啟用/停用切換,以及可為每個實體設定的選用自訂識別碼。
歐盟資料駐留
若需歐盟資料駐留,請更新:
- CDN URL 為
https://cdn-eu.fastcomments.com - Site URL 為
https://eu.fastcomments.com
小工具區塊 
可以在 結構 > 區塊佈局 (/admin/structure/block) 找到多個區塊:
- FastComments Widget - 主要的留言小工具。會自動偵測目前的實體。會跳過已經包含 FastComments 欄位的實體(以避免重複)。
- FastComments Live Chat - 即時串流聊天。可以與同頁面的留言欄並列放置。
- FastComments Collab Chat - 文字選取註記與討論。
- FastComments Image Chat - 基於座標的影像註記。
- FastComments Recent Comments - 顯示整個網站的近期留言。留言數量可設定。
- FastComments Top Pages - 顯示留言數最多的頁面。
以內容為中心的區塊(Live Chat、Collab Chat、Image Chat)會自動偵測目前的實體,且在非實體頁面上會退回使用基於路徑的識別碼。
權限 
- Administer FastComments - 存取 FastComments 的設定表單。
- View FastComments - 需要此權限才能查看評論小工具。
- Toggle FastComments - 允許使用者透過欄位小工具針對每個實體啟用或停用評論。
運作方式 
當使用者造訪啟用了 FastComments 欄位的實體時:
- FastComments 的 JavaScript 小工具會從 CDN 載入。
- 如果已設定 SSO,使用者的 Drupal 身分會傳送給 FastComments。
- 一個
<noscript>回退機制會為沒有 JavaScript 的使用者提供伺服器端渲染的留言(僅限 Live Comments 與 Streaming Chat 模式)。
需要幫助?
如果您在使用 Drupal 模組時遇到任何問題或有任何疑問,請:
貢獻
歡迎任何貢獻!請造訪 GitHub 儲存庫 以取得貢獻指南。