1👍
✅
NO, you cant execute JavaScript in email templates.
Due to serious security issues, most of the email clients block JavaScript from executing. that’s why your redirection script doesn’t work.
the solution is to use an <a>
tag with a URL that specifies the page link instead of <button>
.
Source:stackexchange.com