Skip to content
ms3Favorites
ms3Favorites
Wishlists for MiniShop3 and other resources — browser storage, DB sync
  1. Extras
  2. ms3Favorites
  3. Snippets
  4. ms3FavoritesShare

Snippet ms3FavoritesShare

Share page for a list by token. URL: /wishlist/share?token=xxx. Outputs the product list and “Copy to my list” button.

Parameters

ParameterDescriptionDefault
tokenToken from URL (usually $_REQUEST['token'])
tplProduct card chunktplFavoritesItem
emptyTplEmpty state chunktplFavoritesEmpty
wrapperTplPage wrapper chunktplFavoritesSharePage

wrapperTpl placeholders

PlaceholderDescription
[[+list]]Product list HTML
[[+token]]Token
[[+count]]Product count

Examples

modx
[[!ms3FavoritesShare]]
fenom
{'!ms3FavoritesShare' | snippet}

With custom chunks:

modx
[[!ms3FavoritesShare?
  &tpl=`tplFavoritesItem`
  &emptyTpl=`tplFavoritesEmpty`
  &wrapperTpl=`tplFavoritesSharePage`
]]
fenom
{'!ms3FavoritesShare' | snippet : [
  'tpl' => 'tplFavoritesItem',
  'emptyTpl' => 'tplFavoritesEmpty',
  'wrapperTpl' => 'tplFavoritesSharePage'
]}

When token is missing or expired, the lexicon string ms3favorites_share_not_found is shown. Use a separate template for the share page so the error message displays correctly.