[WordPress] 外掛分享: Keyword-Based Bulk Category Assignment for WooCommerce

首頁外掛目錄 › Keyword-Based Bulk Category Assignment for WooCommerce
全新外掛
安裝啟用
尚無評分
24 天前
最後更新
問題解決
WordPress 6.0+ PHP 7.4+ v1.2.4 上架:2025-07-27

內容簡介

總結: 這個外掛可幫助您在匯入大批未分類商品時,省去大量手動工作時間。它讓您依照分類設定基於關鍵字的規則,並在批量中應用到所選產品。

問題與答案:
1. 這個外掛的主要功能是什麼?
- 可以在匯入大批未分類商品時,省去手動工作時間,並設定基於關鍵字的規則,批量應用到選定的產品。

2. 可以透過這個外掛做哪些事情?
- 建立具彈性的關鍵字規則。
- 支援「OR」邏輯以及透過特殊語法的「AND」邏輯。
- 透過「不包含」關鍵字排除產品。
- 對產品清單中選定的產品批量應用規則。
- 匯入並匯出規則作為 JSON 檔案進行備份與轉移。

3. 如何建立並保存規則?
- 前往 WooCommerce > 關鍵字類別規則。
- 為每個現有的類別輸入:包含:用逗號分隔的關鍵字 (例如:鞋子, 運動鞋);不包含:應排除產品的關鍵字 (例如:損壞, 使用過)。
- 若要要求多個單字一同出現,用「AND」在其間 (以「」):例如:鞋子「AND」皮革是指包含「鞋子」和「皮革」的標題。
- 儲存您的規則。

4. 如何應用這些規則到產品上?
- 在 WooCommerce 產品清單中,選擇您要處理的產品。
- 在批量操作選單中,選擇應用基於關鍵字的類別規則,然後點選應用。
- 外掛將評估所有選定的產品、指派匹配的類別,並顯示一個成功通知。

5. 這個外掛的限制是什麼?
- 這個外掛不會在創建或匯入新產品時自動分配類別,分配工作必須透過批量操作手動觸發。
- 比對僅針對產品標題進行。

6. 這個外掛的免責聲明是什麼?
- 本外掛為獨立專案,與 WooCommerce、Automattic 或任何相關品牌無任何隸屬關係。

外掛標籤

開發者團隊

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

① 下載 ZIP → 後台「外掛 › 安裝外掛 › 上傳外掛」
② 後台搜尋「Keyword-Based Bulk Category Assignment for WooCommerce」→ 直接安裝(推薦)
📦 歷史版本下載

原文外掛簡介

Keyword-Based Bulk Category Assignment for WooCommerce reduces repetitive category work after product imports or catalog updates. Create rules once, select products in the WooCommerce Products list, review the exact planned assignments, and apply them only after confirmation.
The plugin adds categories to a product. It does not remove unrelated categories that are already assigned.
Main features

Create separate include and exclude rules for every WooCommerce product category.
Use simple terms with OR logic.
Combine multiple required terms in an AND group.
Search product titles, short descriptions, full descriptions, SKUs, and attributes.
Keep the product title as the backward-compatible default search field after an upgrade.
Preview every planned category assignment before products are changed.
See which term or AND group caused a match.
Undo the most recently applied run for the current administrator.
Filter the rules table by category name or show configured categories only.
Save rules from controls directly above or below the rules table.
Export and import rules as compact, legacy-compatible JSON.
Preserve rules created with version 1.0 and its established comma / "AND" syntax.

Rule logic
Simple terms use OR
Enter separate terms as individual chips. A category matches when at least one Contains chip matches the selected product fields.
Example:
shoes, sneakers, boots

This means shoes OR sneakers OR boots.
AND groups require every term
Choose + AND group, enter at least two comma-separated terms, and press Enter.
Example input in the AND-group editor:
red, leather

The plugin stores this as:
red "AND" leather

Both terms must occur in the searchable product content. Simple terms and AND groups can be combined in the same rule. For example, shoes, red "AND" leather means shoes OR (red AND leather).
Exclusions take priority
Rules in Does not contain use the same chip and AND-group logic. If any exclusion chip or exclusion AND group matches, the category is skipped even if a Contains rule matches.
Matching details

Matching is case-insensitive.
HTML markup is ignored.
Repeated whitespace is normalized.
German umlauts are normalized so, for example, Müller also matches mueller.
Terms are substring matches; choose specific terms to avoid broad unintended matches.

How to use the plugin

Go to WooCommerce > Category Auto Rules.
Select the product fields that the rules should search. Existing installations default to Title.
Find the desired category. The category hierarchy and term ID are displayed for clarity.
Add one or more terms under Contains. Press Enter or leave the input to accept the text.
Add optional exclusions under Does not contain.
Use + AND group when multiple terms must occur together.
Save with the button above or below the table.
Go to Products, select the products to evaluate, and choose Apply Category Auto Rules (Preview first) from Bulk actions.
Review the planned assignments and the matching reasons.
Confirm the preview to apply new categories. Use Undo last run in the success notice if the result needs to be reverted.

Import and export
Export downloads all category rules as JSON. The exported structure intentionally keeps the option format used by earlier releases, so it can also be read by version 1.0.
Import replaces the current category rules only. Before replacement, version 1.2.4 stores a backup of the previous rules. The Restore pre-import backup action can swap back to that rule set. The global product-field selection is not overwritten. Imports are restricted to valid JSON files up to 2 MB.
Category rules are keyed by WooCommerce term ID. When rules are moved between different stores, corresponding categories should use the same term IDs. Review the imported rows before applying rules to products.
Backward compatibility
Version 1.2.4 continues to use the original keywbuca_category_rules WordPress option and the original rule keys contains and not_contains. Existing rules are available immediately after the update; no destructive migration or activation cleanup runs.
The original syntax remains valid:

commas separate OR blocks;
the literal "AND" joins required terms inside one block;
title-only matching remains the default until an administrator enables more fields.

As a precaution for any production update, export the existing rules and create a normal site/database backup before installing a new plugin version. After updating, open the rules screen, confirm the stored rules, save once, and test a small product selection through the preview.
Privacy
The plugin does not contact external services, create public-facing cookies, or transmit product data. Rules, preview data, and undo data remain in the WordPress installation.
License
This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 2 of the License, or (at your option) any later version.

延伸相關外掛

文章
Filter
Mastodon