Uploaded image for project: 'CiviCRM'
  1. CiviCRM
  2. CRM-15624

Unsubscribe links broken in search-based mailings

    Details

    • Type: Bug
    • Status: Done/Fixed
    • Priority: Major
    • Resolution: Fixed/Completed
    • Affects Version/s: 4.5, 4.5.4
    • Fix Version/s: 4.6
    • Component/s: CiviMail
    • Labels:
    • Documentation Required?:
      None

      Description

      Unsubscribe links in mailings may be broken depending on how the mailing is created.

      When a mailing is created from the results of a search (a search-based mailing) an Unsubscription Group must be entered. If the mailing is written and sent all in one go, then unsubscribe links in the mailing will work.

      However, if a search-based mailing is saved and then continued from the list of draft mailings, the Unsubscription Group will be deleted from civicrm_mailing_group, which means that when the mailing is sent, unsubscribe links will not work. Clicking on an unsubscribe link will display a minimal error page with the message "Sorry but we are not able to provide this at the moment. There was an error in your request".

      This is an aspect of CRM-14079: "search-based mailings may or may not be re-used". As CRM-14079 was deemed to be "non-critical" and its resolution "non-trivial" it has been pushed back to later releases. However, as it is vital that subscribers are able to unsubscribe themselves (a legal requirement in the US and other countries) it is logged here as a separate major bug to be fixed in 4.5.

      BACKGROUND:
      When a mailing is created using CiviMail's New Mailing link, the form has five stages. By contrast, when a mailing is created from search results, the form has six stages - the extra first stage representing the search itself.

      The problem arises because when a search-based mailing is continued from the list of draft mailings, it is suddenly treated as a normal (non-search-based) mailing: The form's first stage - the search stage - is missing, and the search results show up in the list of Include Groups as a "Hidden Smart Group". Crucially, the Unsubscription Group field is missing, and the Unsubscription Group is deleted from civicrm_mailing_group.

      FIX:
      When a search-based mailing is continued, it should be treated as a search-based mailing and use the appropriate six-stage version of the form. The Unsubscription Group should be displayed, and should not be deleted from civicrm_mailing_group.

      Search-based mailings can be identified by checking for a record in civicrm_mailing_group with a group_type of 'base'. (This is the Unsubscription Group.)

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                atif.shaikh Atif Shaikh
                Reporter:
                kirk Kirk Jackson
              • Votes:
                0 Vote for this issue
                Watchers:
                4 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: