Part of the problem here is that the SPEC is 'broken'. How do you select with XPath an element that is in a default namespace? There is no prefix you can place in the XPath statement!!! Your stuck! I had this problem with parsing some XHTML the other day where everything was in the default namespace. In XSLT you're template can specifiy the same namespace as the default and then IIRC you get a match, but what if you had to deal with multiple namespaces? The entire concept of default namespaces makes me grind my teeth. Its like autovivification of variables and hash keys in perl. Anyone designing XML processing systems DO NOT USE DEFAULT NAMESPACES, ever ever ever!
On Friday 28 March 2003 05:31 am, Matt Sergeant wrote: > On Fri, 28 Mar 2003, Daniel Veillard wrote: > > > > my $parser = XML::LibXML->new(); > > > > my $xml = $parser->parse_string( <<EOM ); > > > > <?xml version="1.0" encoding="iso-8859-1"?> > > > > <foo xmlns="urn:bar"> > > > > <value>FOO!</value> > > > > </foo> > > > > EOM > > > > > > > > # you'd expect "FOO!", but... > > > > print "VALUE: ", $xml->findvalue( '/foo/value' ), "\n"; > > > > No it's not brokeness, libxml2 implements the spec. If findvalue > > claims to implements the XPath spec expression evaluation then AxKit > > is broken !!! The XPath spec is cristal clear [1] that the expression > > /foo/value > > only match foo and value node which are in NO namespace > > Just to concur with Daniel here, and make sure there's no thinking that > AxKit is "broken", XML::LibXML does the right thing here (according to the > spec, as Daniel suggests) and by inference, so does AxKit. > > I really don't want anyone to think or suggest that AxKit is broken. There > are bugs (would be foolish to imply that any significant software was bug > free) but not here. > > To get back to the thread, we really need to see stylesheets before we can > debug Simon's problem further. -- Tod Harter Giant Electronic Brain --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
