| 开发者 | motylanogha |
|---|---|
| 更新时间 | 2026年10月24日 02:53 |
| PHP版本: | 8.1 及以上 |
| WordPress版本: | 7.1 |
| 版权: | GPLv2 or later |
| 版权网址: | 版权信息 |
aria-pressed state that updates over AJAX.plogins-versus text domain, and a plogins-versus.pot template ships in /languages. Deleting the plugin removes its options and the comparison table.
How it works
Adding or removing a product is a single nonce-verified AJAX request; no full page reload. Guest selections are kept in a per-browser cookie for six months and merged into the account on login. The CSS and JavaScript are enqueued only on pages that actually show the compare button or the table.
/wp-content/plugins/plogins-versus, or install via Plugins > Add New.Yes. Versus requires an active WooCommerce installation.
No. The plugin's own front-end script is vanilla JavaScript with no jQuery dependency.
Yes, when "Allow guests" is enabled. A guest's comparison is stored per browser, and the View comparison link opens their table without an account: on the My Account Compare address above the login form, or on a page of your choice that holds the [versus] shortcode (set it under "Comparison page for guests"). That page is excluded from page caching, since each visitor sees their own list. When the guest logs in, the list is merged into their account.
On shop and archive loops (classic templates and block-theme product grids such as the Product Collection block) and on the single product page, depending on your settings. The comparison itself opens on the My Account "Compare" tab. A guest sees the same table there above the login form, or on the comparison page you chose for guests.
The table can show product image, name, price, SKU, availability, short description and product attributes such as size, colour or material.
Yes. Difference highlighting and a "differences only" toggle help shoppers focus on what actually changes between compared products.
Yes. Logged-in customers get a My Account Compare tab. Guest compare lists can be merged into the account after login.
Yes. This plugin is compatible with WordPress Multisite. Network activate it or activate it on individual sites; each site keeps its own settings and data.
[versus] shortcode instead. That page is excluded from page caching.aria-describedby, a polite live region that announces compare changes to screen readers, visible focus styles and full keyboard operability.Domain Path header and a versus.pot template in /languages (WordPress loads the translations automatically).uninstall.php cleanup that removes the plugin options and the comparison-items table when the plugin is deleted.