Changeset 19622 for trunk/wp-includes/comment.php
- Timestamp:
- 12/21/2011 10:57:42 AM (13 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/wp-includes/comment.php
r19593 r19622 571 571 } 572 572 573 /** 574 * Sets the cookies used to store an unauthenticated commentator's identity. Typically used 575 * to recall previous comments by this commentator that are still held in moderation. 576 * 577 * @param object $comment Comment object. 578 * @param object $user Comment author's object. 579 * 580 * @since 3.4.0 581 */ 582 function wp_set_comment_cookies($comment, $user) { 583 if ( $user->ID ) 584 return; 585 586 $comment_cookie_lifetime = apply_filters('comment_cookie_lifetime', 30000000); 587 setcookie('comment_author_' . COOKIEHASH, $comment->comment_author, time() + $comment_cookie_lifetime, COOKIEPATH, COOKIE_DOMAIN); 588 setcookie('comment_author_email_' . COOKIEHASH, $comment->comment_author_email, time() + $comment_cookie_lifetime, COOKIEPATH, COOKIE_DOMAIN); 589 setcookie('comment_author_url_' . COOKIEHASH, esc_url($comment->comment_author_url), time() + $comment_cookie_lifetime, COOKIEPATH, COOKIE_DOMAIN); 590 } 591 573 592 /** 574 593 * Sanitizes the cookies sent to the user already.
Note: See TracChangeset
for help on using the changeset viewer.