1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17
|
--TEST--
Bug #70001 (Assigning to DOMNode::textContent does additional entity encoding)
--EXTENSIONS--
dom
--FILE--
<?php
$element = new DOMText('<p>foo & bar</p>');
var_dump($element->textContent);
$element = (new DOMDocument())->createTextNode('<p>foo & bar</p>');
var_dump($element->textContent);
$element->textContent = ('<p>foo & bar</p>');
var_dump($element->textContent);
?>
--EXPECT--
string(16) "<p>foo & bar</p>"
string(16) "<p>foo & bar</p>"
string(16) "<p>foo & bar</p>"
|