post-page

WordPress/b2 Hack – Ping Blogrolling.com

1
response
by
 
on
October 21st, 2003
in
Weblog Add-Ons

I knew that Blogrolling.com gets its “recently updated blogs” information from both blo.gs and weblogs.com, but I was recently having some problems with my site showing up on the updated list, but not updated on Blogrolls. I took a closer look at the problem (the links matched exactly) and found nothing of suspicion. So I decided to fix the problem by pinging Blogrolling.com directly through b2/Wordpress. Here is what I did:

1) In your b2-include folder, find b2function.php and add this code somewhere within the php tags, preferably after the weblogs.com ping. (Yes, the code is very similar to the other pingers with just a few changes)


// pings Blogrolling.com
function pingBlogRolling($blog_ID = 1) {
// original function by Dries Buytaert for Drupal
global $use_weblogsping, $blogname,$siteurl,$blogfilename;
if ((!(($blogname=="my weblog") && ($siteurl=="http://example.com") && ($blogfilename=="b2.php"))) && (!preg_match("/localhost\//",$siteurl)) && ($use_weblogsping)) {
$client = new xmlrpc_client("/pinger/", "rpc.blogrolling.com", 80);
$message = new xmlrpcmsg("weblogUpdates.ping", array(new xmlrpcval($blogname), new xmlrpcval($siteurl."/".$blogfilename)));
$result = $client->send($message);
if (!$result || $result->faultCode()) {
return(false);
}
return(true);
} else {
return(false);
}
}

2) Now find b2edit.php in the main b2 folder and find the line
pingBlogs($blog_ID);
Add the following line right after that:
pingBlogRolling($blog_ID);

And…voila! you are done and pinging Blogrolling.com 🙂
The above hack is explained for b2. b2edit.php resides in the wp-admin directory in WordPress; everything else remains the same. Hope this helps someone!

heading
heading
One
Response

 

Comments

  1. Dr. L says:

    Cool website ! !



Obviously Powered by WordPress. © 2003-2013

css.php