mirror of
https://github.com/php/php-src.git
synced 2024-09-22 02:17:32 +00:00
a555cc0b3d
Remove most of the `===DONE===` tags and its variations. Keep `===DONE===` if the test output otherwise becomes empty. Closes GH-4872.
20 lines
369 B
PHP
20 lines
369 B
PHP
--TEST--
|
|
SimpleXML: Attribute compared to string
|
|
--SKIPIF--
|
|
<?php if (!extension_loaded("simplexml")) print "skip"; ?>
|
|
--FILE--
|
|
<?php
|
|
|
|
$doc = simplexml_load_string('<root><name attr="foo">bar</name></root>');
|
|
print $doc->name["attr"];
|
|
print "\n";
|
|
if ($doc->name["attr"] == "foo") {
|
|
print "Works\n";
|
|
} else {
|
|
print "Error\n";
|
|
}
|
|
?>
|
|
--EXPECT--
|
|
foo
|
|
Works
|