Subject: Re: [xsl] Extract attribute from markup returned by extension function From: John <john-xsl-list@xxxxxxxx> Date: Wed, 03 Aug 2005 12:09:23 -0700 |
(a) do you want an XSLT 1.0 or 2.0 solution?
(b) how robust must it be? Do you have to deal with pathological input such as
<img alt='src="this/is/a/decoy"' src="this/is/real"/>
Michael Kay
http://www.saxonica.com/
-----Original Message-----
From: John [mailto:john-xsl-list@xxxxxxxx] Sent: 03 August 2005 18:17
To: xsl-list@xxxxxxxxxxxxxxxxxxxxxx
Subject: [xsl] Extract attribute from markup returned by extension function
Hello,
An XSL extension function returns markup such as <img src="/path/to/image.jpg" border="0" alt="" />. I can't guarantee the / will be provided so it may not be XML markup. I am only interested in the value of the src attribute. I am hoping the code can be as flexible as possible (attributes could appear in any order, and it would be nice to support single quotes (') in addition to double-quotes (") in the data. I was thinking of starting with the string functions, but I am curious if there might be a better way.
TIA,
-John
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
Re: [xsl] "xmlns" problem for trans, Chenzhou Cui | Thread | RE: [xsl] Extract attribute from ma, Michael Kay |
[xsl] "xmlns" problem for transform, Chenzhou Cui | Date | Re: [xsl] "xmlns" problem for trans, Joris Gillis |
Month |