Changeset 3717
- Timestamp:
- 04/19/2006 03:03:27 AM (19 years ago)
- Location:
- trunk/wp-includes
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/wp-includes/functions-formatting.php
r3713 r3717 1033 1033 } 1034 1034 1035 // Borrowed from the PHP Manual user notes. Convert entities, while 1036 // preserving already-encoded entities: 1037 function htmlentities2($myHTML) { 1038 $translation_table=get_html_translation_table (HTML_ENTITIES,ENT_QUOTES); 1039 $translation_table[chr(38)] = '&'; 1040 return preg_replace("/&(?![A-Za-z]{0,4}\w{2,3};|#[0-9]{2,3};)/","&" , strtr($myHTML, $translation_table)); 1041 } 1042 1035 1043 ?> -
trunk/wp-includes/functions.php
r3716 r3717 1364 1364 } 1365 1365 1366 // Borrowed from the PHP Manual user notes. Convert entities, while1367 // preserving already-encoded entities:1368 function htmlentities2($myHTML) {1369 $translation_table=get_html_translation_table (HTML_ENTITIES,ENT_QUOTES);1370 $translation_table[chr(38)] = '&';1371 return preg_replace("/&(?![A-Za-z]{0,4}\w{2,3};|#[0-9]{2,3};)/","&" , strtr($myHTML, $translation_table));1372 }1373 1374 1366 /* 1375 1367 add_query_arg: Returns a modified querystring by adding … … 1671 1663 return $installed; 1672 1664 } 1665 1673 1666 ?>
Note: See TracChangeset
for help on using the changeset viewer.