|
Subject: Re: [xsl] getting "Cannot create an attribute node (...) whose parent is a document node" when copying attribute nodes through an XSLT function From: "Norman Tovey-Walsh ndw@xxxxxxxxxx" <xsl-list-service@xxxxxxxxxxxxxxxxxxxxxx> Date: Tue, 30 Jun 2020 16:19:11 -0000 |
> <!-- make a copy of the attributes (a proxy for processing) and return
them -->
> <xsl:function name="mine:recopy">
Try <xsl:function name="mine:recopy" as="attribute()*">
I think whatbs happening is that, because your function doesnbt declare
its return type, what itbs returning is wrapped in a document node and
you canbt do that with attributes.
As a general rule, declare the types of your parameters and what your
functions and templates construct.
Be seeing you,
norm
--
Norman Tovey-Walsh <ndw@xxxxxxxxxx>
https://nwalsh.com/
> One of my most productive days was throwing away 1000 lines of
> code.--Ken Thompson
[demime 1.01d removed an attachment of type application/pgp-signature which had a name of signature.asc]
| Current Thread |
|---|
|
| <- Previous | Index | Next -> |
|---|---|---|
| Re: [xsl] getting "Cannot create an, Graydon graydon@xxxx | Thread | Re: [xsl] getting "Cannot create an, Chris Papademetrious |
| Re: [xsl] getting "Cannot create an, Graydon graydon@xxxx | Date | Re: [xsl] getting "Cannot create an, Chris Papademetrious |
| Month |