On Sun, Oct 5, 2008 at 11:46 AM, Josh Matthews <joshmatthews@gmail.com>wrote:
> On Sun, Oct 5, 2008 at 5:47 AM, Florent Georges <fgeorges@fgeorges.org>wrote:
>
>>
>>
> What about the following:
>>
>> <p:delete>
>> <p:with-option name="match" select="
>> if ( exists(//a) ) then //a else '/..'"/>
>> </p:delete>
>
>
> Well, yes, that would work - but that comes back to my original point about
> XML flexibility.
>
Another clarification: that actually wouldn't work. "if (...) then ..." is
not a valid XSLT Pattern.
So you would have to wrap in a <p:choose> or a <p:try> to do that.
Cheers,
Josh Matthews