Changeset 7106

Show
Ignore:
Timestamp:
02/29/08 17:49:50 (9 months ago)
Author:
ryan
Message:

Use preg_replace_callback instead of 'e' modifier. see #5644

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • trunk/wp-includes/kses.php

    r6630 r7106  
    882882 
    883883    $string = preg_replace('/&([A-Za-z][A-Za-z0-9]{0,19});/', '&\\1;', $string); 
    884     $string = preg_replace('/&#0*([0-9]{1,5});/e', 'wp_kses_normalize_entities2("\\1")', $string); 
     884    $string = preg_replace_callback('/&#0*([0-9]{1,5});/', create_function('$matches', 'return wp_kses_normalize_entities2($matches[1]);'), $string); 
    885885    $string = preg_replace('/&#([Xx])0*(([0-9A-Fa-f]{2}){1,2});/', '&#\\1\\2;', $string); 
    886886