Skip to content

Instantly share code, notes, and snippets.

@sebcode
Created May 22, 2011 13:05
Show Gist options
  • Save sebcode/985444 to your computer and use it in GitHub Desktop.
Save sebcode/985444 to your computer and use it in GitHub Desktop.
xslt function
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
xmlns:fn="http://exslt.org/functions"
xmlns:my="http://example.com"
exclude-result-prefixes="fn my">
<xsl:output method="xml"/>
<fn:function name="my:test">
<fn:result select="'result123'"/>
</fn:function>
<xsl:template match="/">
<p>
<p><xsl:value-of select="my:test()"/></p>
</p>
</xsl:template>
</xsl:stylesheet>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment