Skip to main content

Allow Purposes in Web Widgets

Use this guide to add allowed or blocked Purposes to constituent records created or updated through a Donorfy Web Widget.

Cristina Gruita avatar
Written by Cristina Gruita
Updated yesterday

Web Widgets can apply Purposes automatically or allow supporters to select the Purposes you choose to display. To use this feature, you must update the HTML generated for your widget.


How Purposes Work in Web Widgets

Purposes are added or removed using hidden fields in the widget HTML. These fields determine which Purposes will be applied when a supporter submits the form.

Two hidden fields are used:

  • AllowedTags: Purposes to be added.

  • BlockedTags: Purposes to be removed.

Each Purpose is identified using a specific format:

Purpose_<PurposeName>

For example:

  • Allow the Purpose Fundraising:

    <input type="hidden" id="ActiveTags" value="Purpose_Fundraising" />
  • Block the Purpose Events:

    <input type="hidden" id="BlockedTags" value="Purpose_Events" />

πŸ“Œ Note: The Purpose name must match exactly as it appears in your Donorfy Purposes list.


Display Purpose Options for Supporters

You can display dropdown lists or checkboxes on the page to allow supporters to choose from specific Purposes.
Their selections must map to the Purpose string format described above.


Naming Requirements for Purposes

To use a Purpose in a Web Widget:

  • The Purpose name must not contain underscores
    ​Example: Christmas_Appeal will not work.

  • The Purpose name must not contain spaces
    Example: Christmas Appeal will not work.

Rename Purposes in Donorfy if needed before using them in widgets.

⚠️Important:
Web Widgets are a Professional only feature. Essential subscribers, please contact us to find out more about upgrading.

Did this answer your question?