Technorati II

Well, it looks like things are more different than I had thought at first. I took a look at the other functions, and it’s quite different. Here’s what I got in place now, and this post is a test.

The function in b2evocore/_functions_pings.php:

/*
* pingTechnorati(-)
*
* pings technorati.com
*
* Hacked into b2evolution by Isaac Schlueter http://isaacschlueter.com
*/
function pingTechnorati(& $blogparams, $display = true ) {
  global $use_technoratiping, $blogfilename;
  if(!$use_technoratiping) return false;
  if( $display ) {
    echo “<div class=”panelinfo”>n”;
    echo ‘<h3>’, T_(’Pinging technorati.com…’), “</h3>n”;
  }
  if( !preg_match( ‘#^http://localhost[/:]#’, $baseurl) ) {
    $client = new xmlrpc_client(”/rpc/ping”, “rpc.technorati.com”, 80);
    $message = new xmlrpcmsg(”weblogUpdates.ping”, array(new xmlrpcval(get_bloginfo(’name’, $blogparams)),
new xmlrpcval(get_bloginfo(’blogurl’, $blogparams).”/”)));
    $result = $client->send($message);
    $ret = xmlrpc_displayresult( $result );
    if (!$result || $result->faultCode()) {
      if( $display ) echo “<p>”, T_(’Aborted (Running on localhost).’), “</p>n</div>n”;
      return(false);
    } else {
      if( $display ) echo ‘<p>’, T_(’Done.’), “</p>n</div>n”;
      return(true);
    }
  } else {
    if( $display ) echo “<p>”, T_(’Aborted (Running on localhost).’), “</p>n</div>n”;
    return(false);
  }
}

Then, in admin/edit_actions.php, I added this:

pingb2evonet($blogparams, $post_ID, $post_title);
pingWeblogs($blogparams);
pingBlogs($blogparams);
pingCafelog($cafelogID, $post_title, $post_ID);
pingTechnorati($blogparams); // <= Add that part

Let’s see if this works now…

2 Responses to “Technorati II”

  1. On February 1st, 2004 at 02:32:40, Isaac Said:

    Woohoo! It worked!

    Pinging technorati.com…
    Response: 0 |||| Thanks for the ping. ||||

    Done.

  2. On February 1st, 2004 at 03:25:11, David Sifry Said:

    Cool, it appears to be working! Keep up the good work. Also, please put your code and advice up on our developers wiki - I’m sure lots of other people would love to learn from your experience.

    developers.technorati.com

    – Dave

Leave a Reply

Comments are moderated like crazy using a variety of plugins. There is a very high likelihood that your comment won't show up right away, especially if you have never commented here before, but it was not deleted.

Please be patient, and do not post your comment more than once. It will show up once it is approved.

You must be logged in to post a comment.