Ticket #3670: 3670.3.diff
File 3670.3.diff, 2.9 KB (added by , 14 years ago) |
---|
-
wp-includes/post-template.php
165 165 function the_content($more_link_text = null, $stripteaser = 0) { 166 166 $content = get_the_content($more_link_text, $stripteaser); 167 167 $content = apply_filters('the_content', $content); 168 $content = str_replace(']]>', ']]>', $content);168 $content = escape_cdata_close( $content ); 169 169 echo $content; 170 170 } 171 171 -
wp-includes/comment.php
1688 1688 $excerpt = apply_filters('the_content', $post->post_content); 1689 1689 else 1690 1690 $excerpt = apply_filters('the_excerpt', $post->post_excerpt); 1691 $excerpt = str_replace(']]>', ']]>', $excerpt);1691 $excerpt = escape_cdata_close( $excerpt ); 1692 1692 $excerpt = wp_html_excerpt($excerpt, 252) . '...'; 1693 1693 1694 1694 $post_title = apply_filters('the_title', $post->post_title); -
wp-includes/formatting.php
1881 1881 $text = strip_shortcodes( $text ); 1882 1882 1883 1883 $text = apply_filters('the_content', $text); 1884 $text = str_replace(']]>', ']]>', $text);1884 $text = escape_cdata_close( $text ); 1885 1885 $text = strip_tags($text); 1886 1886 $excerpt_length = apply_filters('excerpt_length', 55); 1887 1887 $excerpt_more = apply_filters('excerpt_more', ' ' . '[...]'); … … 2906 2906 2907 2907 } 2908 2908 2909 ?> 2909 /** 2910 * Escapes closing CDATA block by splitting the closing tag between two sections. 2911 * 2912 * @since 3.1.0 2913 * @link http://core.trac.wordpress.org/ticket/3670 2914 * 2915 * @param string $str String with CDATA block to escape 2916 * @return string String with CDATA block escaped 2917 */ 2918 function escape_cdata_close( $str ) { 2919 return '<![CDATA[' . str_replace( ']]>', ']]]><![CDATA[]>', $str ) . ']]>'; 2920 } 2921 2922 ?> 2923 No newline at end of file -
wp-includes/deprecated.php
1734 1734 $excerpt .= ($use_dotdotdot) ? '...' : ''; 1735 1735 $content = $excerpt; 1736 1736 } 1737 $content = str_replace(']]>', ']]>', $content);1737 $content = escape_cdata_close( $content ); 1738 1738 echo $content; 1739 1739 } 1740 1740 -
wp-includes/feed.php
145 145 $feed_type = get_default_feed(); 146 146 147 147 $content = apply_filters('the_content', get_the_content()); 148 $content = str_replace(']]>', ']]>', $content);148 $content = escape_cdata_close( $content ); 149 149 return apply_filters('the_content_feed', $content, $feed_type); 150 150 } 151 151