Support #4618
closedMore struggles with base URIs and receivers
0%
Description
Hi Mike,
I think we've had a couple of conversations on the mailing list around this topic and it's come up again.
I've been trying to clean up my XInclude implementation a bit. If I get an XInclude element that points to a document with a fragment identifier, I end up reaching into the target document and pulling a few nodes out. These nodes get inserted into the source document where the xi:include element had been. (Not telling you anything you don't already know!)
Where they're inserted, I need to do xml:base fixup, adding explicit xml:base attributes so that the base URIs are preserved even as they're inserted into a new document.
Trouble is, the base URI keeps falling on the floor. Maybe I'm just abusing the receiver in some unsupported manner. I extracted it all out into a single test case that I think reproduces the core issue.
The base URIs are present in the original document, but not on the inserted nodes. At one point, I thought maybe the fact that I was appending nodes was causing the base URI to get lost. I added a an attempt to set it on the wrapper element and that doesn't get a base URI either.
A base URI set on the destination propagates through, but that's not sufficient because the base URI may need to vary between elements.
Am I doing something wrong? Is there any hope for making this work?
Files
Please register to edit this issue