Make WordPress Core

Changeset 10236


Ignore:
Timestamp:
12/21/2008 09:03:23 AM (16 years ago)
Author:
azaozz
Message:

htmlspecialchars_decode() for php versions less than 5.1, props sivel, fixes #8679

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/wp-includes/compat.php

    r7140 r10236  
    9797}
    9898
     99// from php.net
     100if ( !function_exists('htmlspecialchars_decode') ) {
     101    function htmlspecialchars_decode( $str, $quote_style = ENT_COMPAT ) {
     102        return strtr( $str, array_flip( get_html_translation_table(HTML_SPECIALCHARS, $quote_style) ) );
     103    }
     104}
     105
    99106?>
Note: See TracChangeset for help on using the changeset viewer.