Update of /cvsroot/php-blog/serendipity
In directory sc8-pr-cvs1:/tmp/cvs-serv8779
Modified Files:
serendipity_functions.inc.php
Log Message:
don't due serial autodiscovery :)
Index: serendipity_functions.inc.php
===================================================================
RCS file: /cvsroot/php-blog/serendipity/serendipity_functions.inc.php,v
retrieving revision 1.20
retrieving revision 1.21
diff -u -d -r1.20 -r1.21
--- serendipity_functions.inc.php 2 Apr 2003 21:02:07 -0000 1.20
+++ serendipity_functions.inc.php 2 Apr 2003 21:14:40 -0000 1.21
@@ -666,11 +666,18 @@
}
function
-serendipity_trackback_autodiscover($res, $url, $author, $title, $text)
+serendipity_trackback_autodiscover($res, $loc, $url, $author, $title, $text)
{
if(!preg_match('@trackback:ping(\s*rdf:resource)?\s*=\s*"(http:[^"]+)"@', $res, $matches)) {
return;
}
+
+ if (preg_match('@dc:identifier\s*=\s*"(http:[^"]+)"@', $res, $test)) {
+ if ($loc != $test[1]) {
+ return;
+ }
+ }
+
$data = "url=".rawurlencode($url)."&title=".rawurlencode($title).
"&blog_name=".rawurlencode($author)."&excerpt=".rawurlencode($text);
$response = serendipity_trackback_is_success(_serendipity_send($matches[2], $data));
@@ -686,7 +693,7 @@
$res .= fgets($fp, 1024);
}
fclose($fp);
- serendipity_trackback_autodiscover($res, $url, $author, $title, $text);
+ serendipity_trackback_autodiscover($res, $loc, $url, $author, $title, $text);
serendipity_pingback_autodiscover($loc, $res);
}
|