Get Started

Configuration

You can customise Wishlist’s settings using a PHP configuration file. This is optional: each setting has a default, so you only need to include the values you want to change.

To override a setting, create wishlist.php in your Craft project’s /config directory and return an array of setting names and values. For example, the following will change the name displayed in the control panel:

<?php

return [
    'pluginName' => 'Wishlist Tools',
];

All other settings keep their defaults. Add any further settings you want to change to the same array. The options below explain the available settings and their defaults.

Configuration Options

pluginName

Type: string · Default: 'Wishlist'

If you want to change the plugin name in the control panel.

Lists

allowDuplicates

Type: bool · Default: false

Whether to allow duplicates in lists.

manageDisabledLists

Type: bool · Default: true

Whether to allow front-end users to manage disabled lists and their items.

mergeLastListOnLogin

Type: bool · Default: false

Whether to merge a user’s lists with all existing lists for the user, when they log in. This can be useful when lists are modified when logged out, but a user logs in. Any existing lists will be merged.

purgeInactiveLists

Type: bool · Default: true

Whether to purge inactive lists after a certain duration.

purgeInactiveListsDuration

Type: string · Default: 'P3M'

If purging inactive lists is enabled, after this duration they will be purged.

purgeInactiveGuestListsDuration

Type: string · Default: 'P1D'

If purging inactive lists is enabled, after this duration only guest lists will be purged.

purgeEmptyListsOnly

Type: bool · Default: true

Whether to purge user lists only if they have no items.

purgeEmptyGuestListsOnly

Type: bool · Default: true

Whether to purge guest lists only if they have no items.

cookieExpiry

Type: mixed · Default: 0

Set how long of an expiry guest users' lists should have, before being forgotten. Provide as 0 to be session-based, or a DateInterval (opens new window) string.

PDF

pdfPath

Type: string · Default: '_pdf/wishlist'

Set the path to your PDF.

pdfFilenameFormat

Type: string · Default: 'Wishlist-{id}'

Set the default PDF filename format.

pdfAllowRemoteImages

Type: bool · Default: true

Whether to allow remote images in the PDF.

pdfPaperSize

Type: string · Default: 'letter'

Sets the paper size for the PDF.

pdfPaperOrientation

Type: string · Default: 'portrait'

Sets the paper orientation for the PDF.

Email

templateEmail

Type: string|null · Default: null

The template Wishlist will use for HTML emails.

attachPdfToEmail

Type: bool · Default: false

Whether to attach the PDF to the email. See PDF settings for generating the PDF.

showListInfoTab

Type: bool · Default: true

Whether the list editing screen displays its information tab.

Control Panel

You can also manage configuration settings through the Control Panel by visiting Settings → Wishlist.