Menu Adam R Brown

WP hooks navigation: Home/browseActions indexFilters index

Source View: comment_form_comments_closed

To save our bandwidth, we show only a snippet of code around each occurence of the hook. View complete file in SVN (without highlighting).

Understanding Source Code

The best way to understand what a hook does is to look at where it occurs in the source code.

Remember, this hook may occur in more than one file. Moreover, the hook's context may change from version to version.

Source View

Line Code
2255      }
2256
2257      // Exit the function when comments for the post are closed.
2258      if ( ! comments_open( $post_id ) ) {
2259           /**
2260            * Fires after the comment form if comments are closed.
2261            *
2262            * @since 3.0.0
2263            */
2264           do_action( 'comment_form_comments_closed' );
2265
2266           return;
2267      }
2268
2269      $commenter     = wp_get_current_commenter();
2270      $user          = wp_get_current_user();
2271      $user_identity = $user->exists() ? $user->display_name : '';
2272
2273      $args = wp_parse_args( $args );