Cut international trackbacks, fixes #1647

git-svn-id: http://svn.automattic.com/wordpress/trunk@3081 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
matt 2005-11-14 10:14:43 +00:00
parent 886de0616c
commit f3c4d80b5e
1 changed files with 4 additions and 1 deletions

View File

@ -70,7 +70,10 @@ if ( !empty($tb_url) && !empty($title) && !empty($tb_url) ) {
$title = wp_specialchars( strip_tags( $title ) );
$title = (strlen($title) > 250) ? substr($title, 0, 250) . '...' : $title;
$excerpt = strip_tags($excerpt);
$excerpt = (strlen($excerpt) > 255) ? substr($excerpt, 0, 252) . '...' : $excerpt;
if ( function_exists('mb_strcut') ) // For international trackbacks
$excerpt = mb_strcut($excerpt, 0, 252, get_settings('blog_charset')) . '...';
else
$excerpt = (strlen($excerpt) > 255) ? substr($excerpt, 0, 252) . '...' : $excerpt;
$comment_post_ID = $tb_id;
$comment_author = $blog_name;