HTML notifications

alt=
DannyA
@dannya
8 years ago
584 posts
Since my last update, all of my notification emails have broken. I was previously sending html emails and now they are going out as text with messed up formatting. What changes were made? How do I re-enable html emails? Set HTML parameter not set in jr user file. Not sure how to enable.
updated by @dannya: 10/31/16 04:56:00AM
brian
@brian
8 years ago
10,148 posts
DannyA:
Since my last update, all of my notification emails have broken. I was previously sending html emails and now they are going out as text with messed up formatting. What changes were made? How do I re-enable html emails? Set HTML parameter not set in jr user file. Not sure how to enable.

I'm not aware of any issues with sending HTML - we do it here with our newsletter. You just need to make sure the "send_as_html" flag is set to 1 on the jrCore_send_email() function call options.


--
Brian Johnson
Founder and Lead Developer - Jamroom
https://www.jamroom.net
sbhadauria
@sbhadauria
8 years ago
129 posts
I need to set send_as_html flag to 1 for signup activation mail. But I don't want to modify jrUser module.
michael
@michael
8 years ago
7,746 posts
All jrCore_send_email() functions create a queue entry via the jrCore_queue_create() function.

There is an event that fires when that queue entry is created 'create_queue_entry'.

If you use your module to listen for that event, you can add in the send_as_html option at that point.

Docs: "Events and Listeners"
https://www.jamroom.net/the-jamroom-network/documentation/jamroom-developers-guide/1011/events-and-listeners

That will allow you to avoid altering the jrUser module.

Tags