mirror of
https://github.com/php/php-src.git
synced 2026-03-24 00:02:20 +01:00
16 lines
374 B
PHP
16 lines
374 B
PHP
--TEST--
|
|
Dom\HTMLDocument serialization escape attribute
|
|
--EXTENSIONS--
|
|
dom
|
|
--FILE--
|
|
<?php
|
|
|
|
$dom = Dom\HTMLDocument::createFromString("<p></p>", LIBXML_NOERROR);
|
|
$p = $dom->documentElement->firstChild->nextSibling->firstChild;
|
|
$p->setAttribute("foo", "<bar>\"'&");
|
|
echo $dom->saveHtml();
|
|
|
|
?>
|
|
--EXPECT--
|
|
<html><head></head><body><p foo="<bar>"'&"></p></body></html>
|