|
@@ 3981-3995 (lines=15) @@
|
| 3978 |
|
* @param int $post_id Post ID. |
| 3979 |
|
* @return array |
| 3980 |
|
*/ |
| 3981 |
|
function get_pung( $post_id ) { |
| 3982 |
|
global $wpdb; |
| 3983 |
|
$pung = $wpdb->get_var( $wpdb->prepare( "SELECT pinged FROM $wpdb->posts WHERE ID = %d", $post_id )); |
| 3984 |
|
$pung = trim($pung); |
| 3985 |
|
$pung = preg_split('/\s/', $pung); |
| 3986 |
|
|
| 3987 |
|
/** |
| 3988 |
|
* Filters the list of already-pinged URLs for the given post. |
| 3989 |
|
* |
| 3990 |
|
* @since 2.0.0 |
| 3991 |
|
* |
| 3992 |
|
* @param array $pung Array of URLs already pinged for the given post. |
| 3993 |
|
*/ |
| 3994 |
|
return apply_filters( 'get_pung', $pung ); |
| 3995 |
|
} |
| 3996 |
|
|
| 3997 |
|
/** |
| 3998 |
|
* Retrieve URLs that need to be pinged. |
|
@@ 4007-4021 (lines=15) @@
|
| 4004 |
|
* @param int $post_id Post ID |
| 4005 |
|
* @return array |
| 4006 |
|
*/ |
| 4007 |
|
function get_to_ping( $post_id ) { |
| 4008 |
|
global $wpdb; |
| 4009 |
|
$to_ping = $wpdb->get_var( $wpdb->prepare( "SELECT to_ping FROM $wpdb->posts WHERE ID = %d", $post_id )); |
| 4010 |
|
$to_ping = sanitize_trackback_urls( $to_ping ); |
| 4011 |
|
$to_ping = preg_split('/\s/', $to_ping, -1, PREG_SPLIT_NO_EMPTY); |
| 4012 |
|
|
| 4013 |
|
/** |
| 4014 |
|
* Filters the list of URLs yet to ping for the given post. |
| 4015 |
|
* |
| 4016 |
|
* @since 2.0.0 |
| 4017 |
|
* |
| 4018 |
|
* @param array $to_ping List of URLs yet to ping. |
| 4019 |
|
*/ |
| 4020 |
|
return apply_filters( 'get_to_ping', $to_ping ); |
| 4021 |
|
} |
| 4022 |
|
|
| 4023 |
|
/** |
| 4024 |
|
* Do trackbacks for a list of URLs. |