wp_get_current_commenter [ WordPress Function ]
wp_get_current_commenter ( No parameters )
| See: | |
| Returns: |
|
| Defined at: |
|
Benzer Fonksiyonlar: wp_get_current_user, wp_set_current_user, wp_count_comments, get_current_screen, get_current_site
Get current commenter's name, email, and URL.
Expects cookies content to already be sanitized. User of this function might wish to recheck the returned array for validity.
Source
<?php
function wp_get_current_commenter() {
// Cookies should already be sanitized.
$comment_author = '';
if ( isset($_COOKIE['comment_author_'.COOKIEHASH]) )
$comment_author = $_COOKIE['comment_author_'.COOKIEHASH];
$comment_author_email = '';
if ( isset($_COOKIE['comment_author_email_'.COOKIEHASH]) )
$comment_author_email = $_COOKIE['comment_author_email_'.COOKIEHASH];
$comment_author_url = '';
if ( isset($_COOKIE['comment_author_url_'.COOKIEHASH]) )
$comment_author_url = $_COOKIE['comment_author_url_'.COOKIEHASH];
return apply_filters('wp_get_current_commenter', compact('comment_author', 'comment_author_email', 'comment_author_url'));
}
?>
Examples [ wp-snippets.com ]
Google Arama Sonuçlarý
- Function Reference/wp get current commenter « WordPress Codex
Description. Get current commenter's name, email, and URL. Expects cookies content to already be sanitized. User of this function might wish to recheck the ...
codex.wordpress.org - #14878 (wp_get_current_commenter filter) – WordPress Trac
while i was doing something around with the comment system, i've noticed that there's no way to change the comment author fields without touching the WP ...
core.trac.wordpress.org - wp_get_current_commenter Wordpress hook details - Adam R Brown
Detailed information about every action hook and filter used in WordPress. Makes Plugin API easier to use. Lists appearance, file location, and deprecation data ...
adambrown.info - wp_get_current_commenter
Function and Method Cross Reference. wp_get_current_commenter(). Defined at : /wp-includes/comment.php -> line 1187. Referenced 3 times: ...
phpxref.ftwr.co.uk