Re: [xml] xmlCopyNode that doesn't copy a namespace?
- From: Daniel Veillard <veillard redhat com>
- To: "Theodore H. Smith" <delete elfdata com>
- Cc: xml gnome org
- Subject: Re: [xml] xmlCopyNode that doesn't copy a namespace?
- Date: Sun, 1 Jan 2006 06:30:11 -0500
On Fri, Dec 30, 2005 at 03:10:08PM +0000, Theodore H. Smith wrote:
Hi people,
I still haven't got an answer on my question to the XPath problem I
was having. In the meantime I've written my own Xpath query function,
which is actually more faster and simple to use than the standard
XPath.
What you implemented is NOT XPath. You break the XPath semantic.
//foo CANNOT select a node which has a namespace even if it's a
default namespace. This is the #1 question of all XPath beginners, not
only you felt in the trap, apparently you didn't checked archives and
decided to implemnent a broken implementation instead, sounds positively
awful !
I'd still like an answer on the XPath problem I posted here,
though. Because I'd like to use the standard tools whereever possible
instead of having to write my own alternatives.
So, I got this problem with xmlCopyNode, it's putting a namespace
into the XML, when I don't actually want one there.
You copy a namespaced element node you gate a namespaced element node
the namespace is as important as the element name in a processor conformant
to XML namespace. You're asking to create a different element, not a copy !
Daniel
--
Daniel Veillard | Red Hat http://redhat.com/
veillard redhat com | libxml GNOME XML XSLT toolkit http://xmlsoft.org/
http://veillard.com/ | Rpmfind RPM search engine http://rpmfind.net/
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]