Re: Odp: [PHP-PEAR] Installation
| From: | Tobias Ratschiller | Date: | Tue, 29 Feb 2000 14:30:24 +0000 |
| Subject: | Re: Odp: [PHP-PEAR] Installation | ||
| References: | 1 2 3 | Groups: | php.pear |
| Request: | Send a blank email to php-pear+get-45@lists.php.net to get a copy of this message | ||
> This maybe is not a Pear-related question, but how (from under php ofcoz')
can I
> distract version, packagename and so on from the above using php script ?
With PHP 4.0 and LibXML, you can use something like
$dom = xmltree($xmlstr);
$children = $dom->root->children;
for($i=0; $i<count($children); $i++)
printf("%s: %s\n", $children[$i]->name,
$children[$i]->children[0]->content)
-Tobias