Show
Ignore:
Timestamp:
07/08/08 23:38:53 (5 months ago)
Author:
ryan
Message:

Fix quotes in captions. Props azaozz. see #6812

Files:

Legend:

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

    r8073 r8290  
    11251125    if ( empty($text) ) return apply_filters('richedit_pre', ''); 
    11261126 
    1127     $output = $text; 
    1128     $output = convert_chars($output); 
     1127    $output = convert_chars($text); 
    11291128    $output = wpautop($output); 
    1130  
    1131     // These must be double-escaped or planets will collide. 
    1132     $output = str_replace('<', '<', $output); 
    1133     $output = str_replace('>', '>', $output); 
    1134  
    1135     // These should be entities too 
    1136     $output = str_replace('<', '&lt;', $output); 
    1137     $output = str_replace('>', '&gt;', $output); 
    1138      
     1129    $output = htmlspecialchars($output, ENT_NOQUOTES); 
     1130 
    11391131    return apply_filters('richedit_pre', $output); 
    11401132}