[xml] newbie question

Hi ,
can someone help a newbie like me on a silly question

I've to replace the value of a node child,something
like this

So I was thinking a naif solution could be 
point a xmlNodePtr n to the parent and
going on until I meet node2
while (n != NULL){
        if (!(xmlStrcmp(n,(const xmlChar *)"node2"))){

But using libxml2 ver. 2.6.20,  the while ends up when
i found the text node reprensenting value1. 

Where I'm wrong ?

Click here to donate to the Hurricane Katrina relief effort.

[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]