mirror of
https://github.com/gosticks/wordpress-develop.git
synced 2026-07-03 00:30:11 +00:00
Fix using htmlspecialchars() whit the $double_encode parameter. PHP < 5.4 doesn't validate the entities.
Props miqrogroove. Fixes #17780. git-svn-id: https://develop.svn.wordpress.org/trunk@32851 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
@@ -34,7 +34,7 @@ class Tests_Formatting_EscHtml extends WP_UnitTestCase {
|
||||
|
||||
function test_ignores_existing_entities() {
|
||||
$source = '& £ " &';
|
||||
$res = '& £ " &';
|
||||
$res = '& £ " &';
|
||||
$this->assertEquals( $res, esc_html($source) );
|
||||
}
|
||||
}
|
||||
|
||||
@@ -85,7 +85,7 @@ class Tests_Formatting_WPSpecialchars extends WP_UnitTestCase {
|
||||
return array(
|
||||
array(
|
||||
'This & that, this & that, — " " Ú " " " " " $ ×',
|
||||
'This & that, this & that, — " &QUOT; Ú " " " " " &dollar; ×',
|
||||
'This & that, this & that, — " &QUOT; Ú " " " " " &dollar; ×',
|
||||
),
|
||||
array(
|
||||
'&& && && &;',
|
||||
|
||||
Reference in New Issue
Block a user