From 1f90fd76bfbcc50d18f868cd9901c58b1e8c06c9 Mon Sep 17 00:00:00 2001 From: Ryan Boren Date: Wed, 11 Jan 2006 21:35:36 +0000 Subject: [PATCH] Trigger pre_ping action outside of loop. Props Mark Jaquith. fixes #2269 git-svn-id: https://develop.svn.wordpress.org/trunk@3427 602fd350-edb4-49c9-b593-d223f7449a82 --- wp-includes/comment-functions.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/wp-includes/comment-functions.php b/wp-includes/comment-functions.php index 96ab53766b..7bbbaacf17 100644 --- a/wp-includes/comment-functions.php +++ b/wp-includes/comment-functions.php @@ -634,10 +634,11 @@ function pingback($content, $post_ID) { $post_links[] = $link_test; elseif(($test['path'] != '/') && ($test['path'] != '')) $post_links[] = $link_test; - do_action('pre_ping', array(&$post_links, &$pung)); endif; endforeach; + do_action('pre_ping', array(&$post_links, &$pung)); + foreach ($post_links as $pagelinkedto){ debug_fwrite($log, "Processing -- $pagelinkedto\n"); $pingback_server_url = discover_pingback_server_uri($pagelinkedto, 2048);