Re: [xml] libxml-1.8.5 is released

Date view Thread view Subject view Author view

From: he@physics.usyd.edu.au
Date: Thu Jan 27 2000 - 20:26:32 EST


On 24 Jan, Daniel Veillard wrote:
>
> Hi,
>
> On Mon, Jan 24, 2000 at 11:15:14AM +1100, he@physics.usyd.edu.au wrote:
>>
>> hi,
>>
>> Two problems:
>>
>> You have the following XML code:
>> <A B="linux is cool">
>> Gnome is cool too.
>> </A>
>>
>> 1. Which sections of the above code do you treat as text nodes? It
>> seems that libxml treats both "linux is cool" and "Gnome is cool too."
>> as text nodes. Hence, according to XMLPath, "linux is cool" should be a
>> child of A since it is a text node? Or should "linux is cool" be
>> regarded part of the attribute, B?
>
> ~/XML -> cat tst2.xml
> <?xml version="1.0"?>
> <A B="linux is cool"> Gnome is cool too. </A>
> ~/XML -> ./tester --debug tst2.xml
> DOCUMENT
> version=1.0
> standalone=true
> ELEMENT A
> ATTRIBUTE B
> TEXT
> content=linux is cool
> TEXT
> content= ...
> ~/XML ->
>
> it's a child of the atribute, attributes have a list of child
> containing text or entity references.

But, I got,

> cat t3.xml
<?xml version="1.0"?>
<A B="linux is cool">
Gnome is cool too.
</A>

> xpathtest --input t3.xml "/child::*/attribute::*/child::*"
Object is a Node Set :
Set contains 0 nodes:

Should it return "linux is cool"?

Hao

>
>> 2. Should /child::A/attribute::B/parent::A give back the node A? I
>> tried testXPath and it returns an empty Node Set.
>
> I still have troubles with the namespace and attributes axis in the
> XPath implementation, it's part of the TODO
>
> Daniel
>

-- 

---------------------------------------------------- Department of Theoretical Physics Tel:61-2-93515770 School of Physics A28 Mob:0410-512027 The University of Sydney Fax:61-2-93517726 NSW 2006 email: he@physics.usyd.edu.au Australia www: http://www.physics.usyd.edu.au/~he/ ____________________________________________________ .~. /V\ L I N U X // \\ >The choice of freedom.< /( )\ www.gamelinux.com ^^-^^ >The choice of linux games< ____________________________________________________ ---- Message from the list xml@xmlsoft.org Archived at : http://xmlsoft.org/messages/ to unsubscribe: echo "unsubscribe xml" | mail majordomo@xmlsoft.org


Date view Thread view Subject view Author view

This archive was generated by hypermail 2b29 : Wed Aug 02 2000 - 12:30:00 EDT