Title: Multiple Category Selection Widget
Author: zackdesign
Published: <strong>2008 年 8 月 23 日</strong>
Last modified: 2026 年 2 月 23 日

---

搜尋外掛

![](https://s.w.org/plugins/geopattern-icon/multiple-category-selection-widget.svg)

# Multiple Category Selection Widget

 由 [zackdesign](https://profiles.wordpress.org/zackdesign/) 開發

[下載](https://downloads.wordpress.org/plugin/multiple-category-selection-widget.4.0.0.zip)

 * [詳細資料](https://tw.wordpress.org/plugins/multiple-category-selection-widget/#description)
 * [使用者評論](https://tw.wordpress.org/plugins/multiple-category-selection-widget/#reviews)
 *  [安裝方式](https://tw.wordpress.org/plugins/multiple-category-selection-widget/#installation)
 * [開發資訊](https://tw.wordpress.org/plugins/multiple-category-selection-widget/#developers)

 [技術支援](https://wordpress.org/support/plugin/multiple-category-selection-widget/)

## 外掛說明

Turn your WordPress post categories into a search powerhouse! This plugin gives 
you a set of dropdown menus based on parent categories and their sub-categories.
Users select one sub-category per parent, and the plugin filters posts matching 
the selected combination.

**Available as:**

 * **Gutenberg Block** — “Multi-Category Filter” in the block inserter (new in v4)
 * **Classic Widget** — “Multi-Category Selection” in Appearance > Widgets
 * **Shortcode** — `[mcsw]` on any page or post

**Features:**

 * AND / OR category filtering — find posts matching ALL or ANY selected categories
 * AJAX chained drilldown — selecting a parent dynamically loads its children
 * Pretty permalink URLs (`/categories/3,5/search_type/and/order/title/`)
 * Ordering by title or default
 * Configurable blank search behavior
 * Exclude specific categories
 * Lightweight — no jQuery, no external dependencies
 * Pagination support
 * Display form above results on category pages (optional)

**Sample use case:**

Real estate — set up parent categories like “Bedrooms”, “Bathrooms”, “Price Range”
with sub-categories beneath them. Users filter listings by selecting from each dropdown.

**Upgrading from v3.x:**

 * PHP sessions have been removed entirely — the URL now carries all state, which
   means better compatibility with caching plugins, load balancers, and modern hosting
 * jQuery has been replaced with vanilla JavaScript
 * CSS classes have changed from `wpmcsw`/`wpmm` to BEM-style `mcsw-*` classes —
   update any custom CSS
 * The old `select-chain.js` in the plugin root has been replaced by `js/select-
   chain.js`

## 適用於區塊編輯器

這個外掛提供 1 個可供 Gutenberg/區塊編輯器使用的區塊。

 *   Multi-Category Filter Filter posts by selecting multiple categories using dropdown
   menus.

## 安裝方式

 1. Upload the plugin folder to `/wp-content/plugins/`
 2. Activate through the Plugins menu
 3. Create parent categories with sub-categories beneath them
 4. Add posts and assign them to the sub-categories

**As a block:**
 In the block editor, search for “Multi-Category Filter” and add
it.

**As a widget:**
 Go to Appearance > Widgets and add “Multi-Category Selection” 
to a sidebar.

**As a shortcode:**
 Add `[mcsw]` to any page or post. Configure the shortcode form
settings under Settings > Multiple Category Selection.

**AJAX chaining example:**

Create a category hierarchy like:
 Country – Australia – State – Vic – NSW – New
Zealand – State – Auckland – Wellington

Enable “AJAX Chaining” in Settings > Multiple Category Selection. Selecting “Australia”
will dynamically show the Australian states.

## 常見問題集

### ANY vs ALL is not working?

Click the “Reset” button first to clear the current filter, then try again.

### The dropdowns aren’t appearing

Dropdowns only appear for parent categories that have sub-categories with published
posts. Make sure your categories have posts assigned.

### Can I style the dropdowns?

Yes. The form uses `.mcsw-form`, each dropdown is in `.mcsw-select-wrap`, and AJAX-
chained results use `.mcsw-chained`. See the plugin’s `css/style.css` for the full
class list.

## 使用者評論

![](https://secure.gravatar.com/avatar/3cff0eddb2478c50d2d602ee6ab817485bb4af4da293e1b20981e724669aa270?
s=60&d=retro&r=g)

### 󠀁[Bad, does not work](https://wordpress.org/support/topic/bad-does-not-work/)󠁿

 [montfrooij](https://profiles.wordpress.org/montfrooij/) 2017 年 1 月 4 日

Bad, does not work

![](https://secure.gravatar.com/avatar/7fd85b9d4ec99c2650efa0a3663fb0e3408db9169c6a682038a00b06314cab8c?
s=60&d=retro&r=g)

### 󠀁[It's buggy for a reason!](https://wordpress.org/support/topic/its-buggy-for-a-reason/)󠁿

 [cyberptyltd](https://profiles.wordpress.org/cyberptyltd/) 2016 年 9 月 3 日

It’s buggy, yes, and likely ment to be to prompt paid support requests. I.e. Asking
a simple question of the developer such as “Will this plugin do XYZ” generates an
email asking you to deposit $40USD for ‘support’ then he’ll answer a question – 
maybe, who knows! Great concept, hopefully one of the pro’s on here will pick up
on it.

![](https://secure.gravatar.com/avatar/9317558fe84c5c7dd946d6fc55c9a5e4190e23e7088b7b3d0f654c5a387f902a?
s=60&d=retro&r=g)

### 󠀁[Problems after searching](https://wordpress.org/support/topic/problems-after-searching/)󠁿

 [LukeHale](https://profiles.wordpress.org/lukehale/) 2017 年 2 月 7 日

This seems to now not work after updating to the latest version. Menu and page appears
all funy after searching. Does anyone know how to fix this or even suggest another
multiple search widget. www.islreal.com regards Luke

![](https://secure.gravatar.com/avatar/55062511e6d45f7438c8f5a84e7ecc32a7c342ffcd2c3f3b3be9b19b8e9522eb?
s=60&d=retro&r=g)

### 󠀁[Bad support](https://wordpress.org/support/topic/bad-support-33/)󠁿

 [word_press.org](https://profiles.wordpress.org/word_pressorg/) 2017 年 2 月 7 
日

Poor quality

 [ 閱讀全部 15 則使用者評論 ](https://wordpress.org/support/plugin/multiple-category-selection-widget/reviews/)

## 參與者及開發者

以下人員參與了開源軟體〈Multiple Category Selection Widget〉的開發相關工作。

參與者

 *   [ zackdesign ](https://profiles.wordpress.org/zackdesign/)

[將〈Multiple Category Selection Widget〉外掛本地化為台灣繁體中文版](https://translate.wordpress.org/projects/wp-plugins/multiple-category-selection-widget)

### 對開發相關資訊感興趣？

任何人均可[瀏覽程式碼](https://plugins.trac.wordpress.org/browser/multiple-category-selection-widget/)、
查看 [SVN 存放庫](https://plugins.svn.wordpress.org/multiple-category-selection-widget/)，
或透過 [RSS](https://plugins.trac.wordpress.org/log/multiple-category-selection-widget/?limit=100&mode=stop_on_copy&format=rss)
訂閱[開發記錄](https://plugins.trac.wordpress.org/log/multiple-category-selection-widget/)。

## 變更記錄

#### 4.0.0

 * New: Gutenberg block — “Multi-Category Filter” available in the block editor
 * New: Lightweight CSS file with clean BEM-style classes
 * Removed: PHP sessions — all search state now carried in URL query parameters
 * Removed: jQuery dependency — AJAX chaining rewritten in vanilla JavaScript
 * Fixed: AJAX chaining now sends the nonce (was broken since v3.2.0)
 * Fixed: Shortcode now returns output instead of echoing (proper shortcode behavior)
 * Fixed: Rewrite rules no longer flushed on every page load (only on activation)
 * Fixed: AJAX handler uses wp_send_json_success() instead of print/die
 * Changed: Admin settings page uses dedicated slug instead of **FILE**
 * Changed: All redirect calls use wp_safe_redirect()
 * Changed: Requires WordPress 6.0+
 * Security: Tightened input validation with sanitize_key(), absint(), whitelist
   checks

#### 3.2.0

 * PHP 8.x compatibility: replaced create_function() with anonymous function
 * Security: ABSPATH guards, nonce verification, input sanitization, output escaping
 * Replaced get_bloginfo(‘url’) with home_url()

#### 3.1.6

 * Tested in WP 4.3.1
 * Updated widget implementation to PHP 5 methodology

#### 3.1.5

 * Tested in WP 3.8
 * Fixed overriding the navigation menu WP script

#### 3.1.4

 * Tested in WP 3.7
 * Fixed media library files missing after plugin search

#### 3.1.3

 * Tested in WP 3.5.2
 * Fixed AND/IN rewrite rules

#### 3.1.1

 * Extensive testing on any/all search
 * Reverted select box layout

#### 3.1

 * Created admin settings page
 * Added shortcode [mcsw]
 * AJAX on/off toggle
 * Form display above results toggle

#### 3.0

 * Support for multiple forms on a page
 * Shortcode support
 * Rewrite rule fixes

#### 2.4

 * Rewrite rules only flush on activation

#### 2.3

 * Fixed variable checking
 * Added title ordering

#### 2.2

 * AJAX chained select boxes

#### 2.1

 * WordPress 2.8+ widget class with multiple instances

#### 2.0

 * Fixed permalink issues
 * All-in-one-SEO and WP Smart Sort compatibility

#### 1.0

 * First release

## 中繼資料

 *  版本 **4.0.0**
 *  最後更新 **3 個月前**
 *  啟用安裝數 **100+**
 *  WordPress 版本需求 ** 6.0 或更新版本 **
 *  已測試相容的 WordPress 版本 **6.9.4**
 *  PHP 版本需求 ** 7.4 或更新版本 **
 *  語言
 * [English (US)](https://wordpress.org/plugins/multiple-category-selection-widget/)
 * 標籤:
 * [category](https://tw.wordpress.org/plugins/tags/category/)[filter](https://tw.wordpress.org/plugins/tags/filter/)
   [post](https://tw.wordpress.org/plugins/tags/post/)[subcategory](https://tw.wordpress.org/plugins/tags/subcategory/)
   [widget](https://tw.wordpress.org/plugins/tags/widget/)
 *  [進階檢視](https://tw.wordpress.org/plugins/multiple-category-selection-widget/advanced/)

## 評分

 2.9 星，滿分為 5 星

 *  [  5 個 5 星使用者評論     ](https://wordpress.org/support/plugin/multiple-category-selection-widget/reviews/?filter=5)
 *  [  1 個 4 星使用者評論     ](https://wordpress.org/support/plugin/multiple-category-selection-widget/reviews/?filter=4)
 *  [  1 個 3 星使用者評論     ](https://wordpress.org/support/plugin/multiple-category-selection-widget/reviews/?filter=3)
 *  [  1 個 2 星使用者評論     ](https://wordpress.org/support/plugin/multiple-category-selection-widget/reviews/?filter=2)
 *  [  6 個 1 星使用者評論     ](https://wordpress.org/support/plugin/multiple-category-selection-widget/reviews/?filter=1)

[Your review](https://wordpress.org/support/plugin/multiple-category-selection-widget/reviews/#new-post)

[查看全部使用者評論](https://wordpress.org/support/plugin/multiple-category-selection-widget/reviews/)

## 參與者

 *   [ zackdesign ](https://profiles.wordpress.org/zackdesign/)

## 技術支援

使用者可在技術支援論壇提出意見反應或使用問題。

 [檢視技術支援論壇](https://wordpress.org/support/plugin/multiple-category-selection-widget/)

## 贊助

想要支援這個外掛的發展嗎？

 [ 贊助這個外掛 ](https://zackdesign.biz)