Reputation: 23
I'm trying to run html signature with javascript in outlook 2013. In the browser it works, but when I'm opening it in Microsoft Outlook it's giving me empty mail. So my question is: Is it possible to run js in outlook? Code with example image is given below
<!DOCTYPE html>
<html>
<head>
<title>Signature</title>
</head>
<body>
<script>
var img = new Image();
var firstPartOfLink = 'http://www.devinrolsen.com/google-maps-marker-icon-counter/marker-maker.php?fontType=ARIAL&fontSize=23&x=16&y=65&r=0&color=255,255,255&image=custom-pin.png&text=Example?';
var now = new Date();
var start = new Date(now.getFullYear(), 0, 0);
var diff = now - start;
var oneDay = 1000 * 60 * 60 * 24;
var day = Math.floor(diff / oneDay);
var stamp = 'stamp=' + day;
var queryString = firstPartOfLink + stamp;
img.src = queryString;
document.body.appendChild(img);
</script>
</body>
</html>
Upvotes: 2
Views: 4548
Reputation: 3098
Emails cannot/shouldn't contain javascript because
Upvotes: 2