- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
How to get subscription and unsubscribe link
Hi,
I am trying to add the Subscribe and Unsubscribe link in email template. But how do I get the URLs? I tried following code but its blank and doesn't work.
<a href="{{var subscriber.getSubscriptionLink()}}">Subscribe</a> | <a href="{{var subscriber.getUnsubscriptionLink()}}">Unsubscribe</a>
How do I get the URL?
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Re: How to get subscription and unsubscribe link
Hi @johndoe86cd
Please try below code, it works for me:
<a href="{{var subscriber.getUnsubscriptionLink()}}">Unsubscribe</a>
Problem Solved? Please click on 'Kudos' & Accept as Solution!
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Re: How to get subscription and unsubscribe link
Does not work for me, i have already used that code as mentioned in my question. I also want Subscription link.
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Re: How to get subscription and unsubscribe link
Hi @johndoe86cd ,
Can you mention on which magento version you are trying this code.
Also mention in which email template you are using above code.
Thanks!
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Re: How to get subscription and unsubscribe link
New Order template, and version is 2.3.5-p1
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Re: How to get subscription and unsubscribe link
Hello,
still waiting for a reply. Can anyone please help?