You are here

function adsense_error in Google AdSense integration 5.2

2 calls to adsense_error()
adsense_admin_settings in ./adsense.module
adsense_get_client_id in ./adsense.module

File

./adsense.module, line 1495

Code

function adsense_error($error_code) {
  switch ($error_code) {
    case ADSENSE_ERROR_NO_MODULE:
      $text = t('No Google Adsense client ID choosing module is enabled. Please check your settings.');
      break;
    case ADSENSE_ERROR_NOT_CONFIGURED:
      $text = t('Could not determine Google Adsense Client ID. Please check your settings.');
      break;
    default:
      $text = t('Unknown Google Adsense error.');
      break;
  }
  drupal_set_message($text, 'error');
}