Re: [xsl] Transforming XML Blockquotes - Mixed Content - XSLT 1.0 Solution

Subject: Re: [xsl] Transforming XML Blockquotes - Mixed Content - XSLT 1.0 Solution
From: Wendell Piez <wapiez@xxxxxxxxxxxxxxxx>
Date: Thu, 14 Apr 2005 18:08:58 -0400
Another thing that slipped through the cracks is the path

$mixed/p[not(preceding-sibling::*[1]/name()='p')]

which, even when $mixed is a node-set, will have to be

$mixed/p[not(preceding-sibling::*[1]/self::p)]

in order to run in a 1.0 processor.

Cheers,
Wendell

At 06:09 PM 4/14/2005, David wrote:
> I guess Saxon 8.4 must do that for me - good to know.

saxon 8 has many virtues, but being a good test bed for a pure xslt1
solution as opposed to an xslt2 one isn't one of them:-)

Backward compatibility mode in recent drafts of XSLT2 is a lot better
than it was in earlier drafts but still the intention of that mode
is to let correct XSLT1 stylesheets work on an XSLT2 processor.

It does not even try to enforce XSLT2 constraints and rules so the fact
that a stylesheet that says version="1.0" works on an XSLT2 processor is
no indication at all that it will work on an XSLT1 processor. Apart from
the fact that result tree fragments no longer exist, you can use the full
range of XPath2 and XSLT2 syntax and all the XPath2  functions, all that
happens if you say version="1.0" is that those functions that were
defined in xslt1 have definitions more closely aligned, but in general
any new functionality works the same way in backward compatibility mode
as it does in native xslt2, not as it does in xslt1.


======================================================================
Wendell Piez                            mailto:wapiez@xxxxxxxxxxxxxxxx
Mulberry Technologies, Inc.                http://www.mulberrytech.com
17 West Jefferson Street                    Direct Phone: 301/315-9635
Suite 207                                          Phone: 301/315-9631
Rockville, MD  20850                                 Fax: 301/315-8285
----------------------------------------------------------------------
  Mulberry Technologies: A Consultancy Specializing in SGML and XML
======================================================================

Current Thread