Forums
New posts
Search forums
Members
Current visitors
Log in
Register
What's new
Search
Search
Search titles only
By:
New posts
Search forums
Menu
Log in
Register
Install the app
Install
Forums
Archive
Archive
XML
Using Xalan for XSL Transformation
JavaScript is disabled. For a better experience, please enable JavaScript in your browser before proceeding.
You are using an out of date browser. It may not display this or other websites correctly.
You should upgrade or use an
alternative browser
.
Reply to thread
Message
[QUOTE="Joe Kesselman, post: 2850214"] After fixing some of the typos and omissions and blatent bad practices in the fragment you showed us (other than the use of extension code where it's probably not necessary and in a way that implies you're forgetting that XSLT doesn't guarantee execution order), it runs without errors in a reasonably recent version of Xalan executed under Java 1.4.1. In fact, modifying the StringBuffer's initialization, I can confirm that it's being passed through and retrieved from successfully. Rebuilt all of Xerces and Xalan under Java 1.5, and ran the stylesheet under that... and it worked fine there too. No Trouble Found in Xalan. If you want help, you're going to have to give us enough information to let us replicate and diagnose the problem. <?xml version="1.0" encoding="utf-8"?> <xsl:stylesheet version="1.0" xmlns:xsl="[URL]http://www.w3.org/1999/XSL/Transform[/URL]" xmlns:Date="java.util.Date" xmlns:StringBuffer="java.lang.StringBuffer" xmlns:parser="es.bfc.xslt.Parser" exclude-result-prefixes="Date StringBuffer parser"> <!-- Stateful extension functions are a BAD PRACTICE! --> <xsl:variable name="updateData" select="StringBuffer:new(' ')"/> <xsl:template match="/"> <script language="javascript"> function setSelectedSelectionCriteriaFields(){ <xsl:value-of select="$updateData" disable-output-escaping="yes" /> } </script> </xsl:template> </xsl:stylesheet> [/QUOTE]
Verification
Post reply
Forums
Archive
Archive
XML
Using Xalan for XSL Transformation
Top