SMF
SMF copied to clipboard
Support List-Unsubscribe header
Description
See RFC 2369 We should support sending List-Unsubscribe header. The work for this is already in place from GDPR unsubscribe links in newsletters. This simply extends that to include the header.
The header would look something like:
List-Unsubscribe: <$scripturl . '?action=notifyannouncements;u=' . $id_member . ';token=' . $token>
Also FYI google is making this a requirement for sending more than 5000 emails per day https://support.google.com/mail/answer/81126#zippy=%2Crequirements-for-sending-or-more-messages-per-day To set up one-click unsubscribe, include both of these headers in outgoing messages:
List-Unsubscribe-Post: List-Unsubscribe=One-Click
List-Unsubscribe: <https://solarmora.com/unsubscribe/example>
The one click requires we pass the data for unsubscribing in the querystring. As well, it seems most providers are only accepting mailto: for it, not http:
On some of my sites I do which allows both the mailto option and the url. I then check if for one click in the url if the data is posted to unsubscribed the user. List-Unsubscribe: mailto:listunsub####@domain.com, https://domain.com/querystring&post List-Unsubscribe-Post: List-Unsubscribe=One-Click