comment_form_fields

comment_form_fields

Appears in: , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , ,
Hook Type: filter

See hook in core

Displaying hooks found in version: wordpress-6.7

apply_filters('comment_form_fields') is found 1 times:

  • /wp-includes/comment-template.php line 2783
    			 * @since 4.4.0
    			 *
    			 * @param array $comment_fields The comment fields.
    			 */
    			$comment_fields = apply_filters( 'comment_form_fields', $comment_fields );
    
    			// Get an array of field names, excluding the textarea.
    			$comment_field_keys = array_diff( array_keys( $comment_fields ), array( 'comment' ) );
    
    			// Get the first and the last field name, excluding the textarea.
    			$first_field = reset( $comment_field_keys );