Make WordPress Core


Ignore:
Timestamp:
09/03/2008 07:54:14 PM (18 years ago)
Author:
ryan
Message:

post_password_required(). fixes #7679

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/wp-includes/comment-template.php

    r8695 r8800  
    803803        }
    804804
    805         if ( !empty($post->post_password) ) { // if there's a password
    806                 if ( !isset($_COOKIE['wp-postpass_' . COOKIEHASH]) || $_COOKIE['wp-postpass_' . COOKIEHASH] != $post->post_password ) {  // and it doesn't match the cookie
    807                         echo __('Enter your password to view comments');
    808                         return;
    809                 }
     805        if ( post_password_required() ) {
     806                echo __('Enter your password to view comments');
     807                return;
    810808        }
    811809
Note: See TracChangeset for help on using the changeset viewer.