Action hook 'comment_form_logged_in_after'

in WP Core File wp-includes/comment-template.php at line 2771

View Source

comment_form_logged_in_after

Action Hook
Description
Fires after the is_user_logged_in() check in the comment form.

Hook Information

File Location wp-includes/comment-template.php View on GitHub
Hook Type Action
Line Number 2771

Hook Parameters

Type Name Description
array $commenter An array containing the comment author's username, email, and URL.
string $user_identity If the commenter is a registered user, the display name, blank otherwise.

Usage Examples

Basic Usage
<?php
// Hook into comment_form_logged_in_after
add_action('comment_form_logged_in_after', 'my_custom_function', 10, 2);

function my_custom_function($commenter, $user_identity) {
    // Your custom code here
}

Source Code Context

wp-includes/comment-template.php:2771 - How this hook is used in WordPress core
<?php
2766  				 * @param array  $commenter     An array containing the comment author's
2767  				 *                              username, email, and URL.
2768  				 * @param string $user_identity If the commenter is a registered user,
2769  				 *                              the display name, blank otherwise.
2770  				 */
2771  				do_action( 'comment_form_logged_in_after', $commenter, $user_identity );
2772  
2773  			else :
2774  
2775  				echo $args['comment_notes_before'];
2776  

PHP Documentation

<?php
/**
				 * Fires after the is_user_logged_in() check in the comment form.
				 *
				 * @since 3.0.0
				 *
				 * @param array  $commenter     An array containing the comment author's
				 *                              username, email, and URL.
				 * @param string $user_identity If the commenter is a registered user,
				 *                              the display name, blank otherwise.
				 */
Quick Info
  • Hook Type: Action
  • Parameters: 2
  • File: wp-includes/comment-template.php
Related Hooks

Related hooks will be displayed here in future updates.