I'm hoping to use email templates in Scheduled reminders that have css in a
<style> tag at the start of the email. Declaring css here for html elements and classes makes MUCH more robust templates that aren't prone to disasters from click-happy admin teams deleting in-line styles.
I can use these templates effectively in CiviMail and when sending emails directly from a contact's summary screen.
However, the Scheduled reminders engine strips out all the css attributes in the initial
<style> tag. So the email looks awful and the
<style> declaration contains all the tags and classes - with no actual css!
I'm guessing this is perhaps something to do with the IDS? I don't see any IDS log errors though. If it is something that we can tell the IDS to ignore, I'd be grateful to know how to do this.
Or is there some other way we can tell the Scheduled reminder system not to strip those attributes?
I'm using 4.6.24 with Drupal 7.54 and CKEditor. Note that the styles aren't being stripped by CK Editor (I've adjusted the editor's config.js to make this possible), because they work perfectly well in CiviMail and from a contact's summary screen... and they are there safely inside the Scheduled reminder email CKEditor screen.
Perhaps it may be useful to add here that I'm not using a
<head> tag to contain my
<style> tag. In my config I haven't been able to persuade CKEDitor to retain the
<head> tags. Nevertheless even so all is well for the other email scenarios.
One final point - I'm aware of how to skip IDS using the following method. So could possibly add an extra path to skip in this: https://github.com/teamsinger/uk.teamsinger.civicrm.mailgun#user-content-skip-ids-checks
Thanks for your help.