Hi,
I can't get the clue. My php page receives an XML document from which I 
need to get the contents and attributes into php variables. I obvious have 
missed something important. Could someone help me with the following script 
(while watching the Bagdad bombings on CNN):
<?
$xml="<?xml version='1.0' ?>"; //if fact, I get the $xml from elsewhere
$xml.="<xmlContainer>";
$xml.="<name>Mike Bosschaert</naam>";
$xml.="</xmlContainer>";
$xmlParser=xml_parser_create();
$parse_succes = xml_parse($xmlParser,$xml,"true");
xml_set_element_handler($xmlParser, "startElement", "endElement");
xml_set_character_data_handler($xmlParser, "characterData");
xml_parse($xmlParser, $datastring, true);
xml_parser_free($xmlParser);
?>
I want to create a variable $name, pointing to "Mike Bosschaert"
Thanks,
Mike


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to