drupal_notify

Versions
4.6 – 5
drupal_notify($server)

Sends a ping to the Drupal directory server.

▾ 1 function calls drupal_notify()

drupal_cron in modules/drupal.module
Implementation of hook_cron(); handles pings to and from the site.

Code

modules/drupal.module, line 138

<?php
function drupal_notify($server) {
  global $base_url;

  $result = xmlrpc($server, 'drupal.site.ping', $base_url, variable_get('site_name', ''), variable_get('site_mail', ''), variable_get('site_slogan', ''), variable_get('site_mission', ''));

  if ($result === FALSE) {
    watchdog('directory ping', t('Failed to notify %server, error code: %errno, error message: %error_msg.', array('%server' => theme('placeholder', $server), '%errno' => theme('placeholder', xmlrpc_errno()), '%error_msg' => theme('placeholder', xmlrpc_error_msg()))), WATCHDOG_WARNING);
  }

}
?>
Login or register to post comments
 
 

All source code and documentation on this site is released under the terms of the GNU General Public License, version 2 and later. Drupal is a registered trademark of Dries Buytaert.