mirror of
https://github.com/php/php-src.git
synced 2024-09-22 02:17:32 +00:00
7485978339
This is an automated migration of most SKIPIF extension_loaded checks.
26 lines
425 B
PHP
26 lines
425 B
PHP
--TEST--
|
|
XMLReader: libxml2 XML Reader, next
|
|
--EXTENSIONS--
|
|
xmlreader
|
|
--FILE--
|
|
<?php
|
|
|
|
$xmlstring = '<?xml version="1.0" encoding="UTF-8"?>
|
|
<books><book num="1"><test /></book><book num="2" /></books>';
|
|
|
|
$reader = new XMLReader();
|
|
$reader->XML($xmlstring);
|
|
|
|
// Only go through
|
|
$reader->read();
|
|
$reader->read();
|
|
|
|
$reader->next();
|
|
echo $reader->name;
|
|
echo " ";
|
|
echo $reader->getAttribute('num');
|
|
echo "\n";
|
|
?>
|
|
--EXPECT--
|
|
book 2
|