xsl-list
[Top] [All Lists]

Re: [xsl] Matching two consecutive hyphens

2016-08-09 11:45:07
On 09.08.2016 18:32, Michele R Combs mrrothen(_at_)syr(_dot_)edu wrote:
Actually, now that I look at it, the contains test appears to be working 
correctly.
The error is showing up in the next line, where I'm trying to get rid of those 
2 dashes:

<xsl:value-of select="replace(.,'--',' ')"/>

The style sheet validates in Oxygen, and using Oxygen I can run the transform 
with no problem.  However, when I try to do it in the browser (Firefox or IE) I 
get this:

Error during XSLT transformation: An unknown XPath extension function was 
called.

So maybe the problem isn't the double dashes but something else?

"replace" is a function introduced in XSLT/XPath 2.0 and as such not supported by the XSLT 1.0 processors the known browsers provide directly. If you want to use XSLT 2.0 client-side then you need to look into Saxon-CE or the recently released Saxon-JS (which is only in beta and I think not yet supported in IE).
--~----------------------------------------------------------------
XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
EasyUnsubscribe: http://lists.mulberrytech.com/unsub/xsl-list/1167547
or by email: xsl-list-unsub(_at_)lists(_dot_)mulberrytech(_dot_)com
--~--

<Prev in Thread] Current Thread [Next in Thread>