Revert [9773]. htmlspecialchars_decode() requires PHP 5.1. see #6992
git-svn-id: https://develop.svn.wordpress.org/trunk@9825 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
parent
b1310e226c
commit
c584cc009a
@ -818,7 +818,7 @@ function comments_template( $file = '/comments.php', $separate_comments = false
|
|||||||
} else if ( empty($comment_author) ) {
|
} else if ( empty($comment_author) ) {
|
||||||
$comments = $wpdb->get_results($wpdb->prepare("SELECT * FROM $wpdb->comments WHERE comment_post_ID = %d AND comment_approved = '1' ORDER BY comment_date", $post->ID));
|
$comments = $wpdb->get_results($wpdb->prepare("SELECT * FROM $wpdb->comments WHERE comment_post_ID = %d AND comment_approved = '1' ORDER BY comment_date", $post->ID));
|
||||||
} else {
|
} else {
|
||||||
$comments = $wpdb->get_results($wpdb->prepare("SELECT * FROM $wpdb->comments WHERE comment_post_ID = %d AND ( comment_approved = '1' OR ( comment_author = %s AND comment_author_email = %s AND comment_approved = '0' ) ) ORDER BY comment_date", $post->ID, htmlspecialchars_decode($comment_author, ENT_QUOTES), $comment_author_email));
|
$comments = $wpdb->get_results($wpdb->prepare("SELECT * FROM $wpdb->comments WHERE comment_post_ID = %d AND ( comment_approved = '1' OR ( comment_author = %s AND comment_author_email = %s AND comment_approved = '0' ) ) ORDER BY comment_date", $post->ID, $comment_author, $comment_author_email));
|
||||||
}
|
}
|
||||||
|
|
||||||
// keep $comments for legacy's sake
|
// keep $comments for legacy's sake
|
||||||
|
Loading…
Reference in New Issue
Block a user