0

htmlmessage question

based on a token , i would like to send a htmlmessage via email. but i see that when i use content.htmlmessage, the email output is blank.. why is this happening

below is the code snippet. it works fine with content.message, but as soon as i repalce it with content.htmlmessage, the email comes out blank.

also the content choices dont work with htmlmessage, but it works fine with content.message.


IF ($content.deviceclassification == "email")
if (exists($event.MsgSubj))
$content.subject = "["&$event.MsgLevel & "]"&" " & "("&$event.MsgCode&")"&" " &":" & $event.MsgSubj
else
$content.subject = "Webench Message"
endif
@script::log("Sending email")
if ($showMessageBody)
if (exists($event.MsgText))
$content.message = $content.message & $event.MsgText & "\n"
else-if (exists($event.MsgHtml))
$content.htmlmessage = $content.htmlmessage & $event.MsgHtml & "\n" else
$content.message = $content.message & "No Message Specified" & "\n"
endif
endif


15 comments

Please sign in to leave a comment.