From ba29615e7edfefdb7471d0bcff31ac032e9b0ed0 Mon Sep 17 00:00:00 2001 From: ryan 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: http://svn.automattic.com/wordpress/trunk@3427 1a063a9b-81f0-0310-95a4-ce76da25c4cd --- 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);