Page 1 of 1

Journaling HTML messages

PostPosted: Thu Oct 15, 2009 6:26 pm
by hedrich
I have set the Journaling feature to create a new record in my existing Communication History table in my solution. The problem is that the value in the $note variable is not evaluating properly if the message was HTML.

The final value set into my field literally ends up looking like this (including double quotes and pilcrows):

"From: Hedrich Michaelsen <[email protected]>¶To: Hedrich Michaelsen <[email protected]>¶Cc: ¶Bcc: ¶Subject: October Postcard¶¶This message is best viewd in HTML.¶¶HTML PART FOLLOWS:¶<!DOCTYPE HTML PUBLIC \"-//W3C//DTD HTML 4.01 Transitional//EN\">¶

This is what goes into the $note variable and subsequently into my message field. It drops a fair amount of what is in the _JournalEntry field in the fmSpark Message table. When it gets to the final script that should evaluate $note if it is enclosed in quotes, that fails because the portion of the text that ends up in $note has lost the final double-quote character. Any clues as to what is going on here? I did make some small and careful modifications to the journaling script to capture a pipe-separated list of enclosures but I don't think this is causing the problem.

PostPosted: Fri Oct 16, 2009 4:22 am
by John Sindelar
Thanks for the details Hedrich; let me look into this (and your plain-text-merge question) and get back to you in a couple days.

Best,

John

PostPosted: Fri Oct 23, 2009 9:59 am
by hedrich
Hi, John:

Have you had any chance to check out the journaling issue? I wanted to add that I see this happening in an un-modified version of fmSpark as well.

Hedrich

PostPosted: Fri Oct 23, 2009 3:10 pm
by John Sindelar
Hi Hedrich,

Sorry for the delay. Interesting bug.

So the problem is in the first SetVariable line in the script "New Action..." in your contacts file (in our Sample Contacts file).

The line setting $note looks like this:
Code: Select all
$note = GetValue ( _argv; 3 ) ];


Replace that with this:
Code: Select all
$note = Right (  _argv ; Length ( _argv ) - Position (  _argv ; "¶" ; 1 ; 2 ) ) ];


That's it.

(When it comes to your other question, about returns in the signature block I'm not sure. You may need to keep putting the signatures in the template block for now. I'm looking at this with the guys from Proof and will let you know what we find.)

Thanks for your patience on this!

PostPosted: Fri Oct 23, 2009 3:19 pm
by hedrich
Super, John. Thanks. I'll give it a shot.

PostPosted: Wed Jun 09, 2010 11:46 am
by Mark Richman
Hi John.

I'm just now getting around to applying these fixes to our copy of fmSpark 1.0.1

My line shows this:
Code: Select all
$note = GetValue ( _argv; 4 )

Should I still change it?