$propbag->add('description', PLUGIN_EVENT_WEBLOGPING_DESC);
$propbag->add('stackable', false);
$propbag->add('author', 'Serendipity Team');
- $propbag->add('version', '1.02');
+ $propbag->add('version', '1.03');
$propbag->add('requirements', array(
'serendipity' => '0.8',
'smarty' => '2.6.7',
}
}
foreach ($this->services as $index => $service) {
- if (isset($serendipity['POST']['announce_entries_' . $service['name']])) {
+ if (isset($serendipity['POST']['announce_entries_' . $service['name']]) || (defined('SERENDIPITY_IS_XMLRPC') && serendipity_db_bool($this->get_config($service['name']))) {
printf(PLUGIN_EVENT_WEBLOGPING_SENDINGPING . '...', $service['host']);
flush();
$http_response = $req->getResponseBody();
$xmlrpc_result = $message->parseResponse($http_response);
if ($xmlrpc_result->faultCode()) {
- echo sprintf(PLUGIN_EVENT_WEBLOGPING_SEND_FAILURE . "<br />", htmlspecialchars($xmlrpc_result->faultString()));
+ $out = sprintf(PLUGIN_EVENT_WEBLOGPING_SEND_FAILURE . "<br />", htmlspecialchars($xmlrpc_result->faultString()));
} else {
- echo PLUGIN_EVENT_WEBLOGPING_SEND_SUCCESS . "<br />";
+ $out = PLUGIN_EVENT_WEBLOGPING_SEND_SUCCESS . "<br />";
+ }
+
+ if (!defined('SERENDIPITY_IS_XMLRPC')) {
+ echo $out;
}
}
}