Hi,

Thank you for the confirmation.  You are right: it seems that the middleware was picking up an older version (8.0). Thanks.

As a note, I understand that this may not be the right forum for this and that I suggested the support of override serialization attributes for result-document, but would it not be cleaner to simply define the different output formats and to just select the proper one at run time with the format attribute (if it wasn't restricted to a literal QName)?

With doctype-system, doctype-public, media-type, and omit-xml-declaration, as well as version, method, indent, and encoding, there are quite a few serialization attributes to determine at run-time and this seems to compete with the <xsl:output/> approach, while selecting the format seems more in-line with xslt2 and with the <xsl:output/> element philosophy.  I hope that it is not too late to improve the standard and I will try to post a case for it on a possibly more appropriate forum.


given something like:

         < xsl:output method= "xml" version= "1.0" encoding= "UTF-8" omit-xml-declaration= "no" indent= "yes" media-type= "application/xml" / >
         < xsl:output name= "jasper" method= "xml" version= "1.0" encoding= "UTF-8" omit-xml-declaration= "no" indent= "yes" media-type= "application/xml" doctype-system= "http://jasperreports.sourceforge.net/dtds/jasperreport.dtd" doctype-public= "//JasperReports//DTD Report Design//EN" / >
         < xsl:output name= "xmlyes" method= "xml" version= "1.0" encoding= "UTF-8" omit-xml-declaration= "no" indent= "yes" media-type= "application/xml" / >
         < xsl:output name= "xmlno" method= "xml" version= "1.0" encoding= "UTF-8" omit-xml-declaration= "no" indent= "no" media-type= "application/xml" / >
         < xsl:output name= "htmlyes" method= "html" version= "1.0" encoding= "UTF-8" omit-xml-declaration= "no" indent= "yes" media-type= "text/html" / >
         < xsl:output name= "htmlno" method= "html" version= "1.0" encoding= "UTF-8" omit-xml-declaration= "no" indent= "no" media-type= "text/html" / >
         < xsl:output name= "packed" method= "xml" version= "1.0" omit-xml-declaration= "yes" encoding= "UTF-8" indent= "no" media-type= "text/html" / >

and assuming that a doctype variable has been assigned the proper output name,
I would rather have :
         < xsl:result-document href= "{$path}" format= "{$doctype}" >
                  < xsl:apply-templates mode= "buildpage" select= "." / >
         < /xsl:result-document >

than
<
xsl:choose >
         < xsl:when test= "$doctype = 'jasper'" >
                  < xsl:result-document href= "{$path}" format= "jasper" >
                           < xsl:apply-templates mode= "buildpage" select= "." / >
                  < /xsl:result-document >
         < /xsl:when >
         < xsl:when test= "$doctype = 'xmlyes'" >
                  < xsl:result-document href= "{$path}" format= "xmlyes" >
                           < xsl:apply-templates mode= "buildpage" select= "." / >
                  < /xsl:result-document >
         < /xsl:when >
         < xsl:when test= "$doctype = 'xmlno'" >
                  < xsl:result-document href= "{$path}" format= "xmlno" >
                           < xsl:apply-templates mode= "buildpage" select= "." / >
                  < /xsl:result-document >
         < /xsl:when >
         < xsl:when test= "$doctype = 'htmlyes'" >
                  < xsl:result-document href= "{$path}" format= "htmlyes" >
                           < xsl:apply-templates mode= "buildpage" select= "." / >
                  < /xsl:result-document >
         < /xsl:when >
         < xsl:when test= "$doctype = 'htmlno'" >
                  < xsl:result-document href= "{$path}" format= "htmlno" >
                           < xsl:apply-templates mode= "buildpage" select= "." / >
                  < /xsl:result-document >
         < /xsl:when >
         < xsl:otherwise >
                  < xsl:result-document href= "{$path}" format= "xmlyes" >
                           < xsl:apply-templates mode= "buildpage" select= "." / >
                  < /xsl:result-document >
         < /xsl:otherwise >
<
/xsl:choose >

or even than:
         < xsl:result-document href= "{$path}" method="{$method}" indent="{$indent}" encoding="{$encoding}" version="{$version}" omit-xml-declaration="{@omit-xml-declaration}" doctype-system="{@doctype-system}" doctype-public="{@doctype-public}" media-type="{@media-type}" >
                  < xsl:apply-templates mode= "buildpage" select= "." / >
         < /xsl:result-document >



Thank you again for your time and consideration
Andre





At 04:20 2005-04-07, you wrote:
I think you must be picking up an old version of the software. These
attributes are certainly permitted.

Michael Kay
http://www.saxonica.com/
 

> -----Original Message-----
> From: saxon-help-admin@lists.sourceforge.net
> [ mailto:saxon-help-admin@lists.sourceforge.net] On Behalf Of
> Andre Cusson
> Sent: 07 April 2005 04:20
> To: saxon-help@lists.sourceforge.net
> Subject: [saxon] change in 8.4 ?
>
> Hi,
>
> 8.4 gives me these errors which 8.3 does not.
>
> 23:14:35,531 INFO  [STDOUT] Error at xsl:result-document on
> line 139 of
> file://WEB-INF/cosmos/persist.xslt:
>    Attribute {method} is not allowed on this element
> 23:14:35,531 INFO  [STDOUT] Error at xsl:result-document on
> line 139 of
> file://WEB-INF/cosmos/persist.xslt:
>    Attribute {indent} is not allowed on this element
> 23:14:35,531 INFO  [STDOUT] Error at xsl:result-document on
> line 139 of
> file://WEB-INF/cosmos/persist.xslt:
>    Attribute {encoding} is not allowed on this element
> 23:14:35,531 INFO  [STDOUT] Error at xsl:result-document on
> line 139 of
> file://WEB-INF/cosmos/persist.xslt:
>    Attribute {omit-xml-declaration} is not allowed on this element
> 23:14:35,531 INFO  [STDOUT] Error at xsl:result-document on
> line 139 of
> file://WEB-INF/cosmos/persist.xslt:
>    Attribute {media-type} is not allowed on this element
>
> As there been a change ?
>
> Thank you,
> Andre
>