bug38949.phpt 453 B

123456789101112131415161718192021222324252627
  1. --TEST--
  2. Bug #38949 (Cannot get xmlns value attribute)
  3. --EXTENSIONS--
  4. dom
  5. --FILE--
  6. <?php
  7. $doc = new DOMDocument();
  8. $doc->load(__DIR__."/nsdoc.xml");
  9. $root = $doc->documentElement;
  10. echo $root->getAttribute("xmlns")."\n";
  11. echo $root->getAttribute("xmlns:ns2")."\n";
  12. $child = $root->firstChild->nextSibling;
  13. echo $child->getAttribute("xmlns")."\n";
  14. echo $child->getAttribute("xmlns:ns2")."\n";
  15. echo "DONE\n";
  16. ?>
  17. --EXPECT--
  18. http://ns
  19. http://ns2
  20. DONE