Menu Adam R Brown

WP hooks navigation: Home/browseActions indexFilters index

Source View: comment_{$new_status}_{$comment->comment_type}

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
2033       *
2034       * Typical comment types include an empty string (standard comment), 'pingback',
2035       * or 'trackback'.
2036       *
2037       * @since 2.7.0
2038       *
2039       * @param int $comment_ID The comment ID.
2040       * @param obj $comment    Comment object.
2041       */
2042      do_action( "comment_{$new_status}_{$comment->comment_type}", $comment->comment_ID, $comment );
2043 }
2044
2045 /**
2046  * Get current commenter's name, email, and URL.
2047  *
2048  * Expects cookies content to already be sanitized. User of this function might
2049  * wish to recheck the returned array for validity.
2050  *
2051  * @see sanitize_comment_cookies() Use to sanitize cookies