HTML rendering in support.js file email.body in case_details field in Cases

  • Running into a issue with the support.js file and incoming tickets. We have a issue where the html is not getting parsed out and is being displayed on the case and is showing the html and headers from the email making it very hard to read. I know there are various ways to accomplish parsing the html out of the data and redisplaying it on the screen by using javascript in the create script or calling someting or running it in the custom content and think you could get at this through a function in SQL as well but none of that matters as I haven't been able to get any of the above to work :-)

    So I was reaching out to see if anyone else had this situation occur and had a solution to geting just the text from the email.body to render in the case_details field.



  • what is the version and patch for this instance?


    Kannan Srinivasan

  • 7.1 patch g

  • We're also having that problem; we're on 7.1g.

    Our workaround is some custom regex in support.js, but it inserts a lot of extra lines and sometimes weird line breaks in the case details field.

  • Did anyone ever find a solution to this?

    We had this working fine on 7.1.g but after some changes that involved a new Outlook profile we are now getting the same problem.

  • Hi,

    We haven't seen this one ourselves - can you raise a support ticket so we can take a look? We'll need a copy of the raw email text (.eml format). The closest issue we've seen is where there was a problem with a bad Content-Transfer-Encoding header, resulting in Base64-encoded attachments showing up in the email body.

    I wouldn't try parsing out HTML using a regex - that way lies madness. Is it just a matter that the HTML needs to be unescaped? You might try using the unescape() function.



  • I can confirm that parsing out HTML with regex is....well, not ideal.

    Will open a ticket.

  • Any updated solution on this? having the same issue on 7.3 SP3

  • I've not seen this as a problem on my little training environment.  I think you'll need to log a case if you have not already done so.

  • Ok, just to double check, when i select the support.js template, is it possible for CRM (or mail manager) to pull the contents of the body of the email and place it into the Case Problem Details field in CRM?

    Right now it only pulls the subject of the email and adds the verbaige: "Please see attached communication for full details."? If i update the template to email.body it pulls the contents however with all the HTML code as well, which is why im trying to find how to parse out the code.