summaryrefslogtreecommitdiffstats
path: root/wp-includes/comment-template.php
diff options
context:
space:
mode:
authordonncha <donncha@7be80a69-a1ef-0310-a953-fb0f7c49ff36>2006-06-23 10:32:27 +0000
committerdonncha <donncha@7be80a69-a1ef-0310-a953-fb0f7c49ff36>2006-06-23 10:32:27 +0000
commit655a7fc3d336fb36671e2d8ab5bda4229aecfdce (patch)
treea377e02196f988c6d3337601fbba79304950da3c /wp-includes/comment-template.php
parentd48e85e0ac5e675ca33fac173f30c75403d1033f (diff)
downloadwordpress-mu-655a7fc3d336fb36671e2d8ab5bda4229aecfdce.tar.gz
wordpress-mu-655a7fc3d336fb36671e2d8ab5bda4229aecfdce.tar.xz
wordpress-mu-655a7fc3d336fb36671e2d8ab5bda4229aecfdce.zip
WP merge
git-svn-id: http://svn.automattic.com/wordpress-mu/trunk@592 7be80a69-a1ef-0310-a953-fb0f7c49ff36
Diffstat (limited to 'wp-includes/comment-template.php')
-rw-r--r--wp-includes/comment-template.php28
1 files changed, 6 insertions, 22 deletions
diff --git a/wp-includes/comment-template.php b/wp-includes/comment-template.php
index 6355a96..c5d5b8f 100644
--- a/wp-includes/comment-template.php
+++ b/wp-includes/comment-template.php
@@ -273,26 +273,12 @@ function pings_open() {
function comments_template( $file = '/comments.php' ) {
global $wp_query, $withcomments, $post, $wpdb, $id, $comment, $user_login, $user_ID, $user_identity;
- if ( is_single() || is_page() || $withcomments ) :
- $req = get_settings('require_name_email');
- $comment_author = '';
- if ( isset($_COOKIE['comment_author_'.COOKIEHASH]) ) {
- $comment_author = apply_filters('pre_comment_author_name', $_COOKIE['comment_author_'.COOKIEHASH]);
- $comment_author = stripslashes($comment_author);
- $comment_author = wp_specialchars($comment_author, true);
- }
- $comment_author_email = '';
- if ( isset($_COOKIE['comment_author_email_'.COOKIEHASH]) ) {
- $comment_author_email = apply_filters('pre_comment_author_email', $_COOKIE['comment_author_email_'.COOKIEHASH]);
- $comment_author_email = stripslashes($comment_author_email);
- $comment_author_email = wp_specialchars($comment_author_email, true);
- }
- $comment_author_url = '';
- if ( isset($_COOKIE['comment_author_url_'.COOKIEHASH]) ) {
- $comment_author_url = apply_filters('pre_comment_author_url', $_COOKIE['comment_author_url_'.COOKIEHASH]);
- $comment_author_url = stripslashes($comment_author_url);
- $comment_author_url = wp_specialchars($comment_author_url, true);
- }
+ if ( ! (is_single() || is_page() || $withcomments) )
+ return;
+
+ $req = get_settings('require_name_email');
+ $commenter = wp_get_current_commenter();
+ extract($commenter);
// TODO: Use API instead of SELECTs.
if ( empty($comment_author) ) {
@@ -309,8 +295,6 @@ function comments_template( $file = '/comments.php' ) {
require( $include );
else
require( ABSPATH . 'wp-content/themes/default/comments.php');
-
- endif;
}
function comments_popup_script($width=400, $height=400, $file='') {