Linux 软件免费装
Banner图

RT Product Search Bar for WooCommerce – Live AJAX Search, SKU Search, Filters & Search Popup

开发者 raintech357
更新时间 2026年11月15日 22:37
PHP版本: 7.4 及以上
WordPress版本: 7.0
版权: GPLv2 or later
版权网址: 版权信息

标签

woocommerce search ajax search live search product search sku search

下载

详情介绍:

Raintech Product Search Bar for WooCommerce is a fast, modern WooCommerce product search plugin. It replaces the slow default WordPress search with a live AJAX search popup: visitors click your search bar (or press / or Ctrl/Cmd + K), the popup opens with the cursor already in the field, and matching products appear instantly as they type – with images, prices, stock status, categories, colour and size filters, price slider and sorting. It is built for stores whose customers search by product name, SKU, batch number or LOT number, and for any shop that wants search that actually finds products – even when the visitor misspells a word, uses the plural, or leaves out an accent. Everything runs on your own server with a lightweight custom search index: no monthly fee, no external search service, no data leaving your site. Support: raintech.pages.dev/contact What is this plugin? It is a complete product-search system for WooCommerce made of four parts that work together:
  1. The search bar and popup – a clean search field (shortcode, block, Elementor widget, widget, or your theme's own search field) that opens a full-width popup with popular searches, recommended products, recent searches and live results.
  2. The search engine – a custom search index with relevance scoring, AND/OR matching, typo correction, synonyms, plurals, SKU, variation and custom-field search.
  3. The sidebar filters – categories, price range, "In stock only", "On sale", and product attributes such as colour, size or brand, shown as checkboxes, radio buttons, buttons, colour swatches or image swatches.
  4. The control panel – a clean settings page in WooCommerce → Product Search with an Index manager, search analytics, appearance options, and export/import of all settings.
Why store owners choose it How it works (in plain language)
  1. You install the plugin and click Build index once. The plugin reads your products (title, description, SKU, categories, tags, attributes, custom fields, variations) and stores every searchable word in its own small database table.
  2. A visitor clicks the search bar. The popup opens and shows popular searches, recent searches and recommended products.
  3. As the visitor types, the plugin looks the words up in the index, ranks products by relevance (a match in the title counts more than a match in the description – you can change the weights), and returns results in a few milliseconds.
  4. If nothing matches, the plugin tries close spellings from your own catalogue and shows "Showing results for…" or "Did you mean…".
  5. The visitor narrows results with the sidebar filters, then clicks a product – or "View all results".
  6. When you add or edit a product, the index updates automatically.
Live search popup Sidebar filters (new) Smart search engine Search by SKU, batch number and LOT number Customers who know a part number don't want to scroll. The plugin indexes the product SKU, every variation SKU, the product ID and any custom field you choose (for example batch_number or lot_number). Type a code – or part of it – and the right product appears at the top. Use your existing search field (no shortcode needed) Enter the class or ID of any search input already on your site (for example .search-field or #site-search) under WooCommerce → Product Search → Integrations. Clicking and/or focusing that field opens the popup. Turn on Seamless integration to take over common theme search forms automatically. Control what appears Appearance Search analytics Integrations Admin tools Settings tabs at a glance Accessibility Focus trap, Esc to close, focus returns to the search bar, visible focus rings, screen-reader labels, labelled loading states and reduced-motion support. Developer notes Shortcode [raintech_search_bar] [raintech_search_bar placeholder="Find a product"]

安装:

  1. Upload the raintech-product-search-bar-for-woocommerce folder to /wp-content/plugins/, or install the zip via Plugins → Add New → Upload Plugin.
  2. Activate the plugin and make sure WooCommerce is active.
  3. Open WooCommerce → Product Search → Index and click "Build index" (needed once; products then stay in sync automatically).
  4. Add the search bar: place [raintech_search_bar] in a page, header template or widget area – or add the "Product Search Bar" block / Elementor widget – or enter your existing search field's class/ID under Integrations, or switch on Seamless integration.
  5. (Optional) Open Sidebar filters to choose how colour, size and other attributes are displayed, and Appearance to pick light/dark theme and the keyboard shortcut.

屏幕截图:

  • Live results with category, colour and size filters, price slider and highlighted search words.
  • Attribute filters as colour swatches, image swatches, radio buttons and checkboxes.
  • Typo correction ("Showing results for…") and "did you mean" suggestions.
  • Dark theme and mobile full-screen popup.
  • Search engine settings: sources, weights, synonyms and stop words.
  • Sidebar filters tab: switches and the attribute mapping table.
  • Index tab with batch rebuild progress.
  • Analytics tab: top searches and searches with no results.

升级注意事项:

1.1.0 Major update. After updating, open WooCommerce → Product Search → Index and click "Build index" once. Requires WordPress 6.6 or newer.

常见问题:

How do I add the search bar to my site?

Use the shortcode [raintech_search_bar] in a page, header template or widget area, add the "Product Search Bar" block in the block editor, drag the Elementor widget, or use the classic widget. You can also make your theme's existing search field open the popup – see below.

Can I use my theme's existing search field instead of the shortcode?

Yes. Under WooCommerce → Product Search → Integrations, enter the CSS class or ID of your existing field (for example .search-field or #site-search; separate several with commas). Choose whether clicking, focusing or both should open the popup. Turn on "Seamless integration" to replace common theme search forms automatically.

How do I search products by SKU?

SKUs are searched by default, including variation SKUs, which show the matching variation (or its parent product). You can raise or lower SKU importance under Search engine → Search in.

How do I search by batch number or LOT number?

Go to Index and add the custom field key that stores the number (for example batch_number or lot_number) to "Custom fields (meta keys)". Re-index once and those values become searchable.

Why are there no results after installing?

Build the search index once under WooCommerce → Product Search → Index. Until then a basic fallback search is used. If you change an index-related setting, a notice asks you to re-index.

Does the index update when I edit products?

Yes. Adding, editing, trashing, restoring or deleting a product updates the index automatically. After large imports or changes to index settings, use "Re-index all products".

Does it fix spelling mistakes?

Yes. If a search finds nothing, the plugin tries close spellings from your own catalogue and shows "Showing results for…". You can turn this off under Search engine.

Does it support synonyms?

Yes, single-word synonyms (for example sofa, couch). Add one group per line under Search engine → Synonyms. Phrase synonyms are not supported.

What is the difference between AND and OR matching?

AND shows only products that match every word the visitor typed. OR shows products matching any word, ranked by how many words they match.

Does it work with product variations?

Yes. Variations are indexed by SKU and attributes. Turn "Show variations as separate results" on or off under Results.

Can visitors filter by colour, size or other attributes?

Yes. Global product attributes (Products → Attributes) appear in the popup sidebar. For each attribute you choose how it is displayed – checkbox list (default), radio buttons (one value at a time), buttons, colour swatches or image swatches – under Sidebar filters → Attribute filters. Values within one attribute combine with OR, different attributes with AND, and counts update as filters change.

How do I show colour swatches or images for attribute values?

Under Sidebar filters → Attribute filters, set the attribute to "Colour swatches" or "Image swatches" and click "Set colours" or "Set images". For colours you can pick a custom colour per value (otherwise the value's name, such as "Red", is used). For images you choose a picture per value from the media library.

Can I show only some attributes?

Yes. Use the switch next to each attribute in the mapping table. Only attributes that actually appear in the current results are shown to visitors.

Can visitors show only in-stock or on-sale products?

Yes. "In stock only" and "On sale" quick filters appear in the sidebar when they would change the results. Each can be turned off under Sidebar filters.

Can I hide certain products or categories from search?

Yes. Use the Filters tab to include or exclude categories and tags, limit by stock or sale status, respect catalog visibility, or hide individual products by name or SKU.

Can I change how the popup looks?

Yes. The Appearance tab lets you choose light, dark or automatic theme, popup width, corner roundness and backdrop darkness. The accent colour is on the Search bar tab.

Is there a keyboard shortcut?

Yes. Turn it on under Appearance: /, Ctrl/Cmd + K, or both. The / key is ignored while the visitor is typing in a field.

What are recent searches?

A short list of the visitor's own last searches shown before they type. It is stored only in their browser (localStorage), never on your server, and they can clear it with one click.

Which pages load the plugin's scripts?

Pages that contain the shortcode, widget or block. If you set an existing-field selector, turn on Seamless integration or enable a keyboard shortcut, the script loads on every page so the popup is always available.

Does it work with Elementor?

Yes. There is a "Product Search Bar" widget in the Elementor panel. You can also use the shortcode in an Elementor shortcode widget.

Does it work with the block editor / block themes?

Yes. Add the "Product Search Bar" block, or place the shortcode in a Shortcode block, a template part or the Site Editor.

Does it work with WPML or Polylang?

Yes. Results are filtered to the visitor's current language, and the index stores each product's language.

Does it work with caching plugins and CDNs?

Yes. Search uses public REST endpoints that do not require a nonce, so cached pages keep working. You can also enable the plugin's own result cache for repeated searches.

Can I track searches in Google Analytics?

Yes. Turn on Google Analytics events under Integrations. The plugin sends a search event with the search term using gtag, the GTM dataLayer or analytics.js, whichever your site already has.

What does the search analytics tab record?

Only the search term, how many times it was searched, whether the last search found products, and the date. No IP addresses, user IDs or cookies. You can delete any term, clear everything, set a retention period or switch logging off.

How can I use the analytics to get more sales?

Look at "Searches that found nothing": each one is a product, synonym or spelling you are missing. Add a synonym, add the product, or add the term to Popular searches. Then check "Top searches" to see what customers want most and feature it.

Does it store anything about my visitors?

No personal data is stored. Recent searches are kept only in the visitor's own browser and are never sent to your server.

Will it slow my site down?

Search runs on an indexed table and averages a few milliseconds per query on a typical catalogue. The popup script is small and loads only where needed.

How is this different from the default WooCommerce / WordPress search?

The default search scans post content with slow queries, ignores SKUs of variations and custom fields, has no typo tolerance, no filters, and no live results. This plugin uses a dedicated index with relevance ranking, finds SKUs and batch/LOT numbers, fixes typos, and adds a live popup with filters.

Do I need a paid search service?

No. Everything runs on your own WordPress and database. There are no external requests and no monthly fees.

Can I move my settings to another site?

Yes. Use Tools → Export settings and Import settings. The search index and analytics are not included in the export.

What happens to my data if I uninstall?

Deleting the plugin removes its settings and database tables (the search index and the analytics log).

Where do I get help?

Contact support at https://raintech.pages.dev/contact.

更新日志:

1.1.0 1.0.1