Run Mail Script in Email Template?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎06-17-2016 08:45 AM
I have to be doing something wrong that someone will see here.
Here is my scenario: A user receives a notification from ServiceNow and has the option to click on a mailto link to send back and kick off an inbound action, similar to the approval emails. I want a the new email to popup with prefilled Subject/Body but I also need to include an email in the CC. I wrote a mail script to add the CC email address. I am calling it in the email template but it just prints the variable and doesn't run. I put in another variable and it seems to work fine. I checked the source code and there isn't any funky HTML happening around it. Can we not call mail scripts in the email templates? If not, what are my options? Much appreciated!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎06-17-2016 10:52 AM
That makes sense that at that point I am in Outlook. Any ideas on how I can make it put an address in the CC when you open? I know the html for that but not sure how to put it inside my template to run when clicked. I am spending entirely too much time on this one item!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎06-17-2016 11:04 AM
no i'm not sure.
i was looking into this a few months back and gave up, because i'm not sure you can auto add a CC.
but re-evaluating this today, i may have an idea. i'll get back to you.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎06-17-2016 12:22 PM
lol i broke my instance looking for an answer for this.
see this thread
help with My Dev instance not working
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎06-17-2016 02:04 PM
aww man, I'm sorry! I won't do whatever you just did. Thanks for the cautionary tale!

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎06-17-2016 02:08 PM
THEORETICALLY (spelled in caps on purpose)...
You can use cc= in your mailto: URL to include Cc addresses. I've only done Subject= before and it works. I haven't tried cc.
Example: mailto:instance@service-now.com?Subject=Approval -- approved&cc=someone@mycompany.com
Reference: https://yoast.com/dev-blog/guide-mailto-links/