Skip to content

Commit e119c72

Browse files
authored
Add a test for setting the innerHTML on a prefixed XML element (#15204)
1 parent 76ad89c commit e119c72

File tree

1 file changed

+13
-0
lines changed

1 file changed

+13
-0
lines changed
Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
--TEST--
2+
Test setting innerHTML on a prefixed element
3+
--EXTENSIONS--
4+
dom
5+
--FILE--
6+
<?php
7+
$dom = Dom\XMLDocument::createFromString('<x:root xmlns:x="urn:x"/>');
8+
$dom->documentElement->innerHTML = '<child><x:subchild/></child>';
9+
echo $dom->saveXML();
10+
?>
11+
--EXPECT--
12+
<?xml version="1.0" encoding="UTF-8"?>
13+
<x:root xmlns:x="urn:x"><child><x:subchild/></child></x:root>

0 commit comments

Comments
 (0)