tag:help-archives.hannonhill.com,2010-02-09:/discussions/xslt-formats/5122-javascript-call-in-xsl-creates-truncated-output-when-used-more-than-onceCascade CMS: Discussion 2014-06-17T19:01:36Ztag:help-archives.hannonhill.com,2010-02-09:Comment/333653982014-06-16T16:10:05Z2014-06-16T16:10:05ZJavascript call in XSL creates truncated output when used more than once<div><p>Hi,<br>
I realize my initial post may not have been perfectly clear, in
that I am referring to javascript called with an XSL format. The
issue is, when I call my javascript function more than once, my
output is completely gone. I'm not sure why this is, but I'm
wondering if you guys have any ideas.</p>
<p>thanks!<br>
Christian</p></div>christiancotag:help-archives.hannonhill.com,2010-02-09:Comment/333653982014-06-16T20:12:55Z2014-06-16T20:12:55ZJavascript call in XSL creates truncated output when used more than once<div><p>Hi Christian,</p>
<p>Not quite sure if this is what you are looking for, but I
noticed the newlines within the <code>address</code> keys weren't
being replaced and saw that <code><xsl:apply-templates
match="address"/></code> was used in a few places. So I added
the following to your Format (above the office hours comment) and
that seemed to resolve that issue:</p>
<pre>
<code><xsl:template match="address"><xsl:value-of select="hh:lineBreakToBR(string(.))"/></xsl:template></code>
</pre>
<p>Please let me know if I am way off here, or you have any
questions.</p>
<p>Thanks!</p></div>Ryan Griffithtag:help-archives.hannonhill.com,2010-02-09:Comment/333653982014-06-17T17:31:39Z2014-06-17T17:31:39ZJavascript call in XSL creates truncated output when used more than once<div><p>Thanks Ryan,<br>
I'm not sure where the issue was in my XSL, but it appears you've
solved my issue, so I'm gonna carry on, anyway, thanks!</p>
<p>Christian</p></div>christiancotag:help-archives.hannonhill.com,2010-02-09:Comment/333653982014-06-17T19:01:34Z2014-06-17T19:01:34ZJavascript call in XSL creates truncated output when used more than once<div><p>Thank you for following up, Christian. I am glad to hear your
Format is working as expected.</p>
<p>I'm going to go ahead and close this discussion, please feel
free to comment or reply to re-open if you have any additional
questions.</p>
<p>Have a great day!</p></div>Ryan Griffith