do_all_pingbacks

函数


do_all_pingbacks ( No parameters )
定义位置
  • wp-includes/comment.php
    , line 2891
引入
5.6.0
弃用

执行所有的pingbacks。

function do_all_pingbacks() {
	$pings = get_posts(
		array(
			'post_type'        => get_post_types(),
			'suppress_filters' => false,
			'nopaging'         => true,
			'meta_key'         => '_pingme',
			'fields'           => 'ids',
		)
	);

	foreach ( $pings as $ping ) {
		delete_post_meta( $ping, '_pingme' );
		pingback( null, $ping );
	}
}