Source for file _ping_b2evonet.plugin.php
Documentation is available at _ping_b2evonet.plugin.php
* This file implements the ping_b2evonet_plugin.
* For the most recent and complete Plugin API documentation
* see {@link Plugin} in ../evocore/_plugin.class.php.
* This file is part of the evoCore framework - {@link http://evocore.net/}
* See also {@link http://sourceforge.net/projects/evocms/}.
* @copyright (c)2003-2006 by Francois PLANQUE - {@link http://fplanque.net/}
* Parts of this file are copyright (c)2004-2006 by Daniel HAHLER - {@link http://thequod.de/contact}.
* {@internal License choice
* - If you have received this file as part of a package, please find the license.txt file in
* the same folder or the closest folder above for complete license terms.
* - If you have received this file individually (e-g: from http://cvs.sourceforge.net/viewcvs.py/evocms/)
* then you must choose one of the following licenses before using the file:
* - GNU General Public License 2 (GPL) - http://www.opensource.org/licenses/gpl-license.php
* - Mozilla Public License 1.1 (MPL) - http://www.opensource.org/licenses/mozilla1.1.php
* {@internal Open Source relicensing agreement:
* Daniel HAHLER grants Francois PLANQUE the right to license
* Daniel HAHLER's contributions to this file and the b2evolution project
* under any OSI approved OSS license (http://www.opensource.org/licenses/).
* @author blueyed: Daniel HAHLER
* @version $Id: _ping_b2evonet.plugin.php,v 1.2.2.2 2006/10/12 21:21:19 blueyed Exp $
if( !defined('EVO_MAIN_INIT') ) die( 'Please, do not access this page directly.' );
* Variables below MUST be overriden by plugin implementations,
* either in the subclass declaration or in the subclass constructor.
var $code =
'ping_b2evonet';
* These variables MAY be overriden.
$this->name =
T_('Ping b2evolution.net');
$this->long_desc =
T_('Pings the b2evolution.net site to include your post in the list of recently updated blogs.');
* Ping the pingomatic RPC service.
global $evonetsrv_host, $evonetsrv_port, $evonetsrv_uri;
$item_Blog =
$params['Item']->get_Blog();
$client =
new xmlrpc_client( $evonetsrv_uri, $evonetsrv_host, $evonetsrv_port);
$client->debug =
($debug &&
$params['display']);
$message =
new xmlrpcmsg( 'b2evo.ping', array(
new xmlrpcval($item_Blog->dget('name', 'xml')),
new xmlrpcval($item_Blog->dget('url', 'xml')),
new xmlrpcval($item_Blog->dget('locale', 'xml')),
new xmlrpcval($params['Item']->dget('title', 'xml' )),
$result =
$client->send($message);
$params['xmlrpcresp'] =
$result;