extension function help
However, I'm currently stuck on trying to create the date. Having problems escaping the data correctly... If I go:
<xsl:variable name="pattern" select="'yyyy-MM-dd\'T\'HH:mm:ss'"/>
<xsl:value-of select="simpledate:new($pattern)"
xmlns:parseposition="java:java.text.ParsePosition"
xmlns:simpledate="java:java.text.SimpleDateFormat"
xmlns:date="java:java.util.Date"/>
Error at xsl:value-of on line 15 of file:/C:/xslt/javascrapper.xslt:
Exception in extension function java.lang.IllegalArgumentException: Illegal pattern character 'p'
however, if I change pattern to:
'yyyy-MM-dd\'T\'HH:mm:ss'
I get:
Error at xsl:variable on line 8 of file:/C:/xslt/javascrapper.xslt:
Error in expression 'yyyy-MM-dd\'T\'HH:mm:ss': Unexpected token <name> beyond
end of expression
if I change to using double quotes:
'yyyy-MM-dd\"T\"HH:mm:ss'
Error at xsl:value-of on line 15 of file:/C:/xslt/javascrapper.xslt:
Exception in extension function java.lang.IllegalArgumentException: Illegal pattern character 'T'
What is the correct way to pass the single quotes inside a string in??
"yyyy-MM-dd\'T\'HH:mm:ss" is the string wanted to be passed into JAVA.

