How can we use EXSLT without loading its source?

XSLTSL seems to argue that we can use EXSLT without loading its source:

Import or enable either the main style sheet or the style module that you want to use directly from the library website; http://xsltsl.sourceforge.net/modules/ . The module catalog always contains the latest stable version.

I tried this:

<?xml version="1.0" encoding="utf-8"?>
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
  <xsl:import href="http://xsltsl.sourceforge.net/modules/string.xsl"/>
  <xsl:output method="text" indent="yes"/>

  <xsl:template match="/">
    <xsl:call-template name="str:to-upper">
      <xsl:with-param name="text">hello world</xsl:with-param>
    </xsl:call-template>
  </xsl:template>
</xsl:stylesheet>

But it does not work. It seems I can not use EXSLT without loading its source.

Is it possible to use EXSLT without loading its source?

+2
source share
2 answers

You are using the library incorrectly. Take a look at the instructions here .

, , :

1) xsl:

<xsl:import href="string.xsl"/>

2) :

xmlns:str="http://xsltsl.org/string"

3) :

<xsl:template match="foo">
  <xsl:call-template name="str:to-upper">
    <xsl:with-param name="text">hello world</xsl:with-param>
  </xsl:call-template>
</xsl:template>

HELLO WORLD.

UPDATE:

, . string.xsl, URL.

+1

,

<xsl:import href="stdlib.xsl"/>

xslt script.

Btw, xslt:

translate(value,"abcdefghijklmnopqrstuvwxyz","ABCBCDEFGHIJKLMNOPQRSTUVWXYZ")

, , .

+1

All Articles