3v4l.org

run code in 300+ PHP versions simultaneously
<?php use Dom\XMLDocument; $xml = XMLDocument::createFromString(<<<EOXML <?xml version="1.0" encoding="UTF-8"?> <note xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="note-nonamespace1.xsd http://localhost/note-nonamespace2.xsd" xsi:schemaLocation="http://www.happy-helpers1.com note-namespace1.xsd http://www.happy-helpers2.com http://localhost/note-namespace2.xsd"> </note> EOXML ); $documentElement = $xml->documentElement; $attributes = $documentElement->attributes; $schemaLocation = $attributes->getNamedItemNS('http://www.w3.org/2001/XMLSchema-instance', 'schemaLocation'); var_dump(explode(' ', $schemaLocation->textContent ?? ''));
Output for git.master, git.master_jit
array(1) { [0]=> string(0) "" }

This tab shows result from various feature-branches currently under review by the php developers. Contact me to have additional branches featured.

Active branches

Archived branches

Once feature-branches are merged or declined, they are no longer available. Their functionality (when merged) can be viewed from the main output page


preferences:
31.11 ms | 405 KiB | 5 Q