[WordPress] 外掛分享: FAQ with categories

首頁外掛目錄 › FAQ with categories
WordPress 外掛 FAQ with categories 的封面圖片
20+
安裝啟用
尚無評分
105 天前
最後更新
0%
問題解決
WordPress 6.0+ PHP 7.4+ v1.5.1 上架:2020-11-22

內容簡介

常見問題解答(FAQ)對於您的訪問者非常有用,在正確的實施下也對於 SEO 相當有幫助。

這個簡單的 FAQ 外掛程式可以建立一個新的文章型態。這個設計直觀且靈活:您現在可以像在 WordPress 中管理其他文章型態一樣來建立和管理常見問題解答。

您可以使用簡碼(shortcodes)呼叫常見問題解答。預設的中央常見問題解答頁面為 [faq-with-categories]。更多選項會在下面和設定頁面中說明。

常見問題解答總是按照已發布日期倒序排序,所以最新的條目會先顯示(您可以操控每篇文章的發布日期)。

您可以選擇一個分類法,預設是「分類(category)」,來附加您的 FAQ 文章。現在您可以在頁面上為特定的分類(包括子分類)呼叫常見問題解答。如果您在中央常見問題解答頁面放置過濾(filter),本外掛程式也會使用它來篩選常見問題解答。

如果您想要在其他位置顯示某些常見問題解答,而這些解答並不顯示在中央頁面,您可以使用「獨佔」標籤(tag)。

當條目非常多時,會自動出現一個「顯示更多」按鈕(可以在設定中自訂)。

優點

管理常見問題解答非常容易

整潔的手風琴式顯示和平順的篩選 / 搜尋

「獨佔」簡碼和中央常見問題解答頁面輸出 ld+json 格式的常見問題解答片段架構資料(FAQ snippets schema)

支援直接連結以預先選擇篩選條件(faq-page?category=category%20name)

自動遵循(選擇的)分類法階層(無限層次),並且新增了選項來排序分類

缺點

只支援 1 個中央常見問題解答列表(但您可以在任何地方顯示常見問題解答的子集合)

目前僅支援簡碼(shortcodes),尚未支援元件(widgets)

篩選和搜尋常見問題解答只有在啟用 JavaScript 的情況下才能使用(但再說一次,WordPress 的大部分功能都需要 JavaScript)

過濾器顯示當前所有的分類,包括沒有常見問題解答的分類,這將在未來的更新版本中修正

簡碼

您可以使用以下簡碼,當然,某些組合並不合理,可能會產生不穩定的行為。

[faq-with-categories](僅使用一次)產生預設列表,包含所有常見問題解答,並在 head 中輸出 FAQ snippets schema。

[faq-with-categories-filter] 依照所選的分類法,在頁面上生成篩選器選單,並使用指定的排序方式(僅在同一頁面中有預設簡碼時可行)。

[faq-with-categories-search] 產生一個搜尋框,可以透過客戶端進行常見問題解答的查詢(僅在同一頁面中有預設簡碼時可行)。

[faq-with-categories quantity=”5″](1)限制常見問題解答的數量為 5,或使用其他數字。可以與其他設定結合使用。

[faq-with-categories category=”category name”](1)僅顯示指定分類(不分大小寫)的常見問題解答。這不會在 head 中輸出 FAQ snippets schema。

[faq-with-categories exclusive=”your tag”](1)(每個標籤只能使用一次)在方框中指定的任何標籤,都會收集該標籤下的所有常見問題解答以供顯示。

[faq-with-categories title-only=”any value”] 將列表作為連結而非手風琴式顯示輸出。

(1)註:頁面上只會出現有限數量的常見問題解答,因此搜尋和篩選將無法使用。

樣板

文章型態稱為 ruigehond010_faq,因此,如果您希望以更多細節格式化顯示,可以建立 single-ruigehond010_faq.php 和 archive-ruigehond010_faq.php 樣板。

玩得開心。

外掛標籤

開發者團隊

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

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

原文外掛簡介

FAQs are great for your visitors and when implemented correctly also for SEO.
This simple FAQ plugin creates a new post-type. This is straightforward and flexible: you can now create and manage FAQs like any other post type in WordPress.
The FAQs can be summoned using shortcodes, the default for the central FAQ page is [faq-with-categories]. More options are explained below and on the settings page.
FAQs are always sorted by published-date descending, so newest entries are first (you can manipulate the published date of each post).
You can choose a taxonomy, the default is ‘category’, to attach your FAQ posts to. You can now summon FAQs for a specific category (including sub categories) on a page. The plugin also uses it to filter the FAQs if you place the filter on your central FAQ page.
If you want some FAQs in other locations that do not appear on the central page you can use an ‘exclusive’ tag.
When there are many entries, a ‘Show more’ button appears automatically (configurable in the settings)
Pros

Easy to manage the FAQs

Tidy accordion display and smooth filtering / searching

The ‘exclusive’ short_code and the central FAQ page output FAQ snippet schema data as ld+json in the head

Supports direct linking to pre-select the filters (faq-page?category=name%20of%20category)

Automatically follows (chosen) taxonomy hierarchy (infinite depth) with added option to order the categories

Cons

Only 1 central FAQ list is supported (though you can display subsets of the FAQs anywhere you want)

Currently only with shortcodes, no widgets

Filtering and searching the FAQs only work with javascript enabled (but then again, so does most of WordPress)

Short codes
You may use the following shortcodes, of course certain combinations do not make sense and may produce erratic behaviour.
[faq-with-categories] produces the default list with all the faqs and outputs FAQ snippets schema in the head. Use only ONCE for central FAQ page, and on pages that are linked to a taxonomy (category) in the plugin.
[faq-with-categories-filter] produces a filter menu according to the chosen taxonomy using the specified order (only works when default shortcode is also on that page).
[faq-with-categories-search] produces a search box that will perform client-side lookup through the faqs (only works when default shortcode is also on that page).
[faq-with-categories quantity=”5″] (1) limits the quantity of the faqs to 5, or use another number. Can be combined with the other settings.
[faq-with-categories category=”category name”] (1) display only faqs for the specified category (case-insensitive). This will NOT output FAQ snippets schema in the head.
[faq-with-categories exclusive=”your tag”] (1) (use only ONCE for every tag) any tag you specified under a faq entry in the box, will gather all faqs with that tag for display.
[faq-with-categories title-only=”any value”] outputs the list as links rather than as an accordion.
(1) NOTE: only a limited number of faqs will be present on the page, searching and filtering will be limited to those.
Template
The post-type is called ruigehond010_faq, so you can create a single-ruigehond010_faq.php and archive-ruigehond010_faq.php template should you want to format the display in more detail.
Have fun. Let me know if you have a question!

延伸相關外掛

文章
Filter
Apply Filters
Mastodon