Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- try {
- $sxe = simplexml_load_string($xmlstring, 'SimpleXMLIterator');
- for ($sxe->rewind(); $sxe->valid(); $sxe->next()) {
- if ($sxe->hasChildren()) {
- foreach ($sxe->getChildren() as $element=>$value) {
- echo $value->species . '<br />';
- }
- }
- }
- }
- catch(Exception $e) {
- echo $e->getMessage();
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement