Favorites Wishlist

Version 5.0.0

Copyright © 2015-2021, Vinos de Frutas Tropicales, contact me here. Current Support Thread on github: https://github.com/lat9/favorites_wishlist_support

Plugin Information: https://vinosdefrutastropicales.com/index.php?main_page=product_info&cPath=2_8&products_id=56


  1. Starting with v5.0.0 of the plugin, only Zen Cart Versions 1.5.6 and later are supported; the minimum PHP version now supported is PHP 5.6. Note, too, that the site's storefront template must now load a version of jQuery for proper operation.
  2. Starting with v3.0.0 of the plugin, I've created a PHP script to convert an existing Wishlist installation to the format required by Favorites Wishlist. I'll distribute that conversion script, upon request, to purchasing customers.
  3. Starting with v2.0.0 of the plugin, only Zen Cart versions 1.5.5a and later are supported. Contact me if you require a previous version while you plan your site's upgrade.
  4. Be sure to review the instructions for either installing or upgrading your Favorites Wishlist installation!


This plugin, modelled after the like-named feature of a major Internet retailer, provides your customers with a Favorites Wishlist where they can save their favorites and then share those favorite selections with friends and family. A customer's favorites can be easily moved between their Favorites Wishlist and their shopping cart.

When a customer arrives at your store, they are presented with a My Favorites link in the top navigation header. On each product's detailed information page, the add-to-cart block includes an Add to Favorites button. Only account-holders at your store have access to Favorites Wishlists (either theirs or a shared wishlist) and they must be logged into your store to complete this access.

Starting with v1.1.0, you use the Configuration->Favorites Wishlist settings to control whether a listing or center-box contains an "Add to Favorites" link for each product in the list.

This plugin is installed on my demo site; you can access my favorites using this link: https://vinosdefrutastropicales.com/demo/index.php?main_page=favorites&fc=2:a87be70787748fbf98daa5acdc13cb80 … after logging in or creating an account.

Zen-Cart Admin Interfaces

Database Changes

On the first logged-in admin-page access after the plugin's files have been copied, the plugin's auto-loaded installation script:

  1. Creates three new tables in your database:
    1. favorites_groups — contains information for each customer-specified favorites' group (Added in v3.0.0)
    2. favorites — contains the primary product information for a customer's favorite selection.
    3. favorites_attributes — contains any product-related attributes for the customer's favorite selection.
  2. Creates the configuration settings for the plugin, accessible via Configuration->Favorites Wishlist, and registers the associated admin page as well as the admin page for Reports->View Favorites Wishlists.

Note: If you are upgrading to Favorites Wishlist v3.0.0 or later from a version prior to v3.0.0, the installation script will create a default, private favorites' group named My Favorites for any customer who has pre-existing favorites.

Configuration->Favorites Wishlist

The following configuration values allow you to customize your store's Favorites Wishlist:

Field Name Field Description
Favorites Wishlist: Version Displays the plugin's version number.
Favorites Wishlist: Release Date Displays the plugin's release date.
Enable Favorites Wishlist? This value controls whether or not the Favorites Wishlist is displayed to your customers. (Default: false)
Shared Wishlist Secret Phrase Enter the "secret phrase" that is used when customers share their wishlists. The value should be cryptographically unique for your store. (Default: Your secret phrase)
Load Minified Scripts?
(Added in v3.0.0)
Instructs the Favorites Wishlist whether to load the minified (true, the default) or full-size (false) versions of any plugin-specific javascript files.
Show Favorites on Add? This value indicates whether or not the favorites page should be displayed to the customer upon an add-to-favorites button click. (Default: true)
Icon on Listing Pages
(Added in v1.1.0)
Choose whether to display the favorites' icon (Button, the default) or a Font Awesome glyph (Font Awesome) as the image to click on listing pages and center-boxes. That image, when clicked, adds the associated product to the customer's favorites (they might need to log in first).

Note: If you choose Font Awesome, it is your responsibility to ensure that the Font Awesome support is previously loaded!
Add-to-Favorites: Centerboxes
(Added in v1.1.0)
This setting chooses the centerboxes (Specials, New and Featured) on which to display the add-to-favorites link. The value you set (a combination of the letters S, N and F) identifies those centerboxes. If you don't want the link to display on any centerboxes, set this to an empty value. (Default: NSF)
Add-to-Favorites: Listings
(Added in v1.1.0)
This setting chooses the listings (Products, Specials, New, All and Featured) on which to display the add-to-favorites link. The value you set (a combination of the letters P, S, N, A and F) identifies those listings. If you don't want the link to display on any listings, set this to an empty value. (Default: PNSAF)
Show Model? Identifies whether or not a product's model (if set) should be displayed on the favorites and shopping_cart pages. (Default: true)
Show Manufacturer Name? Identifies whether or not a product's manufacturer's name (if set) should be displayed on the favorites and shopping_cart pages. (Default: true).
Enable Debug? Controls whether (true) or not (false) the store-side processing should create debug-log files for problem-determination. If enabled, the processing will write records to a myDEBUG-favorites-*.log file, present in your store's /logs directory. (Default: false)

Reports->View Favorites Wishlists

Displaying the Customers' Wishlists

Starting with v1.2.0 of this plugin, this admin-level tool allows you to view the current contents of your customers' wishlists. That tool displays the most-popular items first, with links to both the associated product and customer pages.

Customer Interfaces

This plugin has been validated using button images as well as CSS buttons. You should review the look-and-feel for both the favorites and shopping_cart pages and make any necessary CSS and/or language-file adjustments.

The Header

Navigation Header Showing the My Favorites Link

When the plugin is enabled, the My Favorites link appears in the upper navigation header of your store. If the customer is not currently logged in, they'll need to login prior to the display of the favorites page.

Add to Favorites (Products' Details)

Add to Favorites from Product Pages

On each of the Zen Cart product and document information pages, the "Add to Cart" block is updated to include an Add to My Favorites button — once you've enabled the plugin. If the customer is not currently logged in, they'll need to login before the action is completed. You control whether the customer is taken to the favorites page or remains on the product information page, based on the Show Favorites on Add? configuration setting.

Add to Favorites (Centerboxes and Listings)

Add to Favorites: Centerboxes Add to Favorites: Products Listing

You can configure each of the Zen Cart "centerboxes" and listing pages (products, specials, new, all and featured) to display an Add to Favorites link. That link is identified either by a Font Awesome glyph (as shown) or an icon-image.

You can control the image and/or glyph displayed by changing the definitions for BUTTON_ADD_TO_FAVORITES or FA_ADD_TO_FAVORITES, respectively. Those definitions are present in /includes/languages/english/extra_definitions/favorites_extra_definitions.php.

The Shopping Cart Page

The Shopping Cart Page, Showing Favorites

Once you've enabled Favorites Wishlist and a customer is logged in, their shopping cart page's display includes additional functionality:

Move to Favorites

There is a new icon below the product-removal icon on the right-hand side of the shopping cart's product table. That icon, if clicked, moves the selected product from the customer's cart to the customer's default Favorites Wishlist group.

Note: If the customer has multiple favorites' groups, the default group can be changed by clicking the Make Default button associated with the to-be-made-default group.

Control the Favorites' Display

If the customer has multiple favorites' groups, they can click the Sort Groups By dropdown to choose the sort-order for their non-default groups — their default group always displays as the first group. That value is maintained in their current login session, so the sort-order gets "remembered" for their session's duration.

The customer also controls whether or not the products associated with a favorites' group are displayed by clicking the leading + (to display) or - (to hide) associated with a specific group.

Move to Cart

The Your Favorite Items block is displayed. If the customer has no current favorites, the display indicates as such. Otherwise, each favorite item is displayed with a Move to Cart button; clicking the button associated with a favorite item moves that item to the customer's cart.

View and Manage Your Favorites

If the customer has items in their Favorites Wishlist, the "View and Manage Your Favorites" link shows. Clicking that link results in the display of the favorites page.

The Your Favorites Wishlist Page

The Favorites Page, Showing Your Favorites

Once you've enabled Favorites Wishlist and a customer is logged in, they can access their favorites page to manage their favorites. This page can display either the currently logged-in customer's favorites or another customer's public favorites.

The text that displays at the top of the page is present in two language-definition pages, present in /includes/languages/english/html_includes:

  1. define_favorites.php. This text is displayed when the currently logged-in customer's favorites are being shown.
  2. define_favorites_other.php. This text is displayed when the favorites being shown are another customer's Favorites Wishlist items.

Note: The page's formatting when displaying another customer's favorites is similar to the screenshot on the left, with the following exceptions:

  1. The Share Your Favorites Wishlist link is not shown.
  2. The "Selected Actions" dropdown allows Add to Cart only.
  3. The "Other Actions" dropdown includes a Display My Favorites action and does not include a Create a Group action.
  4. You cannot "Edit", "Remove" or change the default for any of the other customer's favorites' groups.
  5. You cannot change a favorite product's priority.

The Share Your Favorites Wishlist Link

Shared Wishlist Popup View

Clicking this button results in a CSS-positioned pop-up to be displayed. That pop-up includes a link to the currently logged-in customer's Favorites Wishlist, which they can copy from the pop-up display and include in an email to friends and family!

The Sort Groups By Dropdown

Changing this selection auto-submits the favorites' form and records the customer's sort-by choice in their login session. That way, the sort-order "sticks" for the customer's visit.

The sort-order selection applies to non-default favorites' groups — the customer's default favorites' group is always displayed first!

The With Selected … Dropdown

Select an action to be performed on all checked-off favorite products, fill in any additional information (see below) and click the Go button.

Add to Cart

This action functions like a multiple add-to-cart button, adding all checked items to the currently logged-in customer's cart. Once all items have been added, the shopping-cart page is displayed if your store's Configuration->My Store>Display Cart After Adding Product is set to "true"; otherwise, the favorites page is re-displayed.

Remove from Favorites

This action permanently removes all checked items from the currently logged-in customer's Favorites Wishlist. The customer is presented with an "Are you sure?" javascript pop-up to confirm the removal.

Move to Different Group

This action is presented to the customer if they have multiple favorites' groups and allows the customer to move products between their favorites' groups.

When the action is selected, a dropdown selection is presented to the customer to choose the "target" favorites' group.

The Other Actions Dropdown

Additional actions are provided to enable the customer to manage his/her favorites. Some of the actions (see below) present the customer with additional form fields. In all cases, the customer clicks the Go button to cause the requested action to be performed.

Display My Favorites

This action, provided only when the customer is viewing a friend's favorites, allows the customer to view their favorites.

Find Friends' Favorites
Find a Friend's Favorites

This action allows the logged-in customer to search for their friends' publically viewable favorites on your site. When the action is selected, additional form fields are presented.

The customer provides their friend's first and last names and email address to locate the friend's favorites.

Create a Group
Create Group Fields

A customer uses this action to create a new favorites' group. When the action is selected, additional form fields are presented.

The customer supplies a name for the new group (no HTML is allowed), identifies the group's public and default status and supplies an (optional) comment for the favorites' group.

Favorites' Groups

When a customer is viewing their favorites, each favorites' group's heading contains one or more additional buttons, allowing the customer to make changes to that specific group.

Each favorites' group that contains at least one product also includes a control (the + or - on the left-most edge of the group's label) that enables the customer to show (clicking +) or hide (clicking -) all products in that group.

Favorite Products

When the customer is viewing their favorites, each favorite product includes a dropdown selection identifying the Priority of their "wish". Changing a selection auto-submits the form to make the requested change.

Version and Change History:

Version History