xsl-list
[Top] [All Lists]

Re: auto-replacing text with hyperlink

2003-08-14 05:42:46
You wrote:

Unfortunately it doesn't. When I used exactly the same template with the XML
document I have, it changed every instance of the word into a hyperlink. I

Looks to me like it will change the first instance in every text() node
which will probably be most instances.

You could try a template which matches only the first text() node
containing the term:
  <xsl:template match="text()[contains(.,$term)][1]">

Oliver

 XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list



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