At 11:39 26/09/01 +0000, [EMAIL PROTECTED] wrote:
>Nigel,
>
>Before releasing 1N6 it would be a Good Thing (tm) to release a 1N5-style
>version of original examples (government for example) to avoid the zillions
>of question I have about : "how does this new way of Xpath.class.php-ing
>work ???"
>
>Luc

Or if you don't have enough time, just tell me what is now the right 
version of this code that worked with xml.php/1N4 :

<buddy_list>
     <buddy id="1">
         <lastname>Doe</lastname>
         <firstname>John</firstname>
         <isniceguy>Yes</isniceguy>
    </buddy>
</buddy_list>

$myatrributesarray = array();
$listofmybuddies = $xml->evaluate('/buddy_list/buddy');
foreach ( $listofmybuddies as $buddy )
{
     $myatrributesarray  = $xml->get_attributes($buddy);
     $id                 = $myatrributesarray['id']
     $firstname        = $xml->get_attributes($buddy ."/firstname[1]");
     $lastname          = $xml->get_content($buddy ."/lastname[1]");
     $isniceguy         = $xml->get_content($buddy ."/isniceguy[1]");
}

--
This message has been sent through the <phpXML/> user discussion list. To unsubscribe, 
please visit https:[EMAIL PROTECTED]/

_______________________________________________
Phpxmldb-phpxml-arc mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/phpxmldb-phpxml-arc

Reply via email to