wphooks.info - comment_max_links_url

comment_max_links_url

(trunk - 5.0-alpha-42177)

The hook occurs in the following file:

wp-includes/comment.php:
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
		/**
		 * Filters the number of links found in a comment.
		 *
		 * @since 3.0.0
		 * @since 4.7.0 Added the `$comment` parameter.
		 *
		 * @param int    $num_links The number of links found.
		 * @param string $url       Comment author's URL. Included in allowed links total.
		 * @param string $comment   Content of the comment.
		 */
		$num_links = apply_filters( 'comment_max_links_url', $num_links, $url, $comment );

		/*
		 * If the number of links in the comment exceeds the allowed amount,
		 * fail the check by returning false.
		 */
		if ( $num_links >= $max_links )
			return false;
	}