generic_ping

函数


generic_ping ( $post_id = 0 )
参数
  • (int)
    $post_id
    Post ID.
    Required:
返回值
  • (int) Same post ID as provided.
定义位置
  • wp-includes/comment.php
    , line 3022
引入
1.2.0
弃用

Sends pings to all of the ping site services.

function generic_ping( $post_id = 0 ) {
	$services = get_option( 'ping_sites' );

	$services = explode( "n", $services );
	foreach ( (array) $services as $service ) {
		$service = trim( $service );
		if ( '' !== $service ) {
			weblog_ping( $service );
		}
	}

	return $post_id;
}