
ms3Favorites
ms3Favorites adds wishlists for MiniShop3 products and other resource types (resources, articles, pages, custom). Users save products for later. The list is stored in the browser (localStorage or cookie), with optional DB sync for logged-in users and guests (when guest_db_enabled).
v3.0.0: resource_type for all entity kinds, mode="list" (hide whole card on remove), mxQuickView and mFilter integration, guest rows in DB, popularity snippet, JS callbacks, Add to cart from the wishlist page.
Wishlist page (ms3FavoritesPage): tabs and page shell. For resource_type=products with serverList=1 (default), product cards are rendered server-side in the chunk (pdoPage + msProducts). With serverList=0, favorites.js fills the list (up to 100 items per tab, no in-chunk paging). For non-product types the list still comes from JS after sync. For a fully custom paginated view use ms3FavoritesIds + pdoPage on another resource (see ms3FavoritesPage, Integration).
Naming: user-facing — ms3Favorites; in code (folders, snippets, lexicon) — ms3favorites.
Features
- Wishlist block — output by list of IDs (AJAX via connector or server-side snippet)
- Browser storage —
localStorage(default) orcookie, no registration - DB sync — for logged-in users: on login, data from localStorage is moved to the DB
- Guests in DB — when
guest_db_enabled, guest list is stored by session_id - Multiple lists —
default,gifts,plans, etc. (up tomax_lists) - List sharing — public link
/wishlist/share?token=xxx, copy someone else’s list - Page /wishlist/ —
ms3FavoritesPage: SSR product list whenserverList=1(default) andresource_type=products; otherwise JSrender; server tab counts andms3f.total; custom pagination viams3FavoritesIds+pdoPageon a separate page - Cart integration — “Add all to cart”, “Add selected”
- Popularity — “In N users’ wishlists”
- Resource types —
products,resources,articles,pages,custom - Localization — MODX Lexicon (ru, en), frontend snippet
ms3fLexiconScript - Customization — Fenom chunks, BEM classes (prefix
ms3f), CSS variables - Catalog row — chunk
tplCatalogRowMs3ffor a favorites button in each pdoPage + msProducts row (integration) - Notifications — chain: optional
ms3fConfig.notify→window.ms3Message.show(MiniShop3) → iziToast (lazy-loaded fromassets/components/ms3favorites/vendor/izitoast/, base URL inms3fConfig.iziToastBaseUrlfromms3fLexiconScript).
System requirements
| Requirement | Version |
|---|---|
| MODX Revolution | 3.0+ |
| PHP | 8.1+ |
| MySQL | 5.7+ / MariaDB 10.3+ |
Dependencies
Installation
See Quick start for requirements and ModStore steps.
Via ModStore
- Connect ModStore repository
- Go to Extras → Installer and click Download Extras
- Ensure MiniShop3 and pdoTools are installed
- Find ms3Favorites, click Download, then Install
- Settings → Clear cache
Package is available at modstore.pro.
After installation
Load lexicon, CSS and JS on the site, add the button on the product card and output the wishlist block.
See: Quick start and Frontend setup.
Terms
| Term | Description |
|---|---|
| Wishlist | List of favorite products (default list is default) |
| Sync | Moving the list from localStorage to the DB when the user logs in |
| Sharing | Public link to a list by token |
| Popularity | Number of users who added the resource to their wishlist |
