- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-23-2018 06:06 AM
I want to use this image in an email script(Notification) so that when clicked on the image in email received then it redirects to servicenow. Below is the email script and I want to add the smiley on the end of notification.Can someone help?
{
template.print('<p><font size="3" color="#808080" face="helvetica">');
template.print(gs.getMessage('If you feel the issue is not resolved, please click the following link and reopen your incident:'));
template.print('</font></p>');
}
template.print('<font face="helvetica">');
var backgroundColor = 'background-color: #278efc;';
var border = 'border: 1px solid #0368d4;';
var color = 'color: #ffffff;';
var fontSize = 'font-size: 16px;';
var fontFamily = 'font-family: Helvetica, Arial, sans-serif;';
var textDecoration = 'text-decoration: none; border-radius: 3px;';
var webKitBorder = '-webkit-border-radius: 3px;';
var mozBorder = '-moz-border-radius: 3px;';
var display = 'display: inline-block;';
var padding = 'padding: 5px;';
if (email_action.name == "Incident Survey") {
color = 'color: #343d47;';
backgroundColor = 'background-color: #e6e8ea;';
border = 'border: 1px solid #bdc0c4;';
}
template.print('<a href="' + link + '"');
template.print('style="' + backgroundColor + border + color + fontSize + fontFamily + textDecoration + webKitBorder + mozBorder + display + padding);
template.print('">');
template.print(gs.getMessage('Take me to the Incident'));
template.print('</a>');
template.print('</font>');
template.print('<br><br>');
template.print('<p><font size="3" color="#808080" face="helvetica">');
template.print('Thank you.');
template.print('</font></p>');
})(current, template, email, email_action, event);
Solved! Go to Solution.
- Labels:
-
Scripting and Coding

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-23-2018 10:51 PM
template.print('<a href="ServiceNow Survey URL"><img src="URL"/></a>');

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-23-2018 10:51 PM
template.print('<a href="ServiceNow Survey URL"><img src="URL"/></a>');
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-26-2018 01:30 AM
Thank you for your reply.Yes it worked successfully.Can I ask for one more favor from you?If you know my below query can you please answer it?
We are building a new survey with smiley😃😟.So we are sending emails with smileys to users from incident.When clicked on a smiley it will redirect to the survey link.I want to store the incident number in an hidden field in the survey page when it is redirected from email.How can I do that?