hi all,
i have an issue with importing document segments from another document.
the target document has all it's content in one namespace, the namespace
is defined and namespace alias's are not used.
the source document is similiar, the difference being that an alias for
this namespace is also defined, and that alias (prefix) is used
throughout that documet.
when i import node trees, the imported segment in the target document
has the namespace alias defined and uses the prefex, even though this is
in the very same namespace as the rest of the document which doesn't use
a prefix/alias.
how can i import that node tree so that the prefix is dropped ?
thks for any feedback
regards
d
PS e.g.
Target doc :
<?xml version="1.0" encoding="UTF-8" standalone="no" ?>
<rootElement xmlns="myNsUri">
<data>
<text>this is data 1</text>
</data>
</rootElement>
Source Doc :
<?xml version="1.0" encoding="UTF-8" standalone="no" ?>
<rootElement xmlns="myNsUri" xmlns:myNsAlias="myNsUri" >
<myNsUri:data>
<myNsUri:text>this is data 2</myNsUri:text>
</myNsUri:data>
</rootElement>
Result of Import to target from source (troublesome)
<?xml version="1.0" encoding="UTF-8" standalone="no" ?>
<rootElement xmlns="myNsUri">
<data>
<text>this is data 1</text>
</data>
<data xmlns:myNsAlias="myNsUri">
<myNsUri:text>this is data 2</myNsUri:text>
</data>
</rootElement>
Required Result of import to target from source
<?xml version="1.0" encoding="UTF-8" standalone="no" ?>
<rootElement xmlns="myNsUri">
<data>
<text>this is data 1</text>
</data>
<data>
<text>this is data 2</text>
</data>
</rootElement>