You are here

function _spamicide_get_description in Spamicide 5

Same name and namespace in other branches
  1. 6 spamicide.module \_spamicide_get_description()
  2. 7 spamicide.inc \_spamicide_get_description()

Show translation if available

Parameters

$lang_code:

Return value

translated field description

1 call to _spamicide_get_description()
spamicide_form_alter in ./spamicide.module
Implementation of hook_form_alter

File

./spamicide.module, line 498
This module provides yet another tool to eliminate spam.

Code

function _spamicide_get_description($lang_code = NULL) {

  // work to be done
  $default = t('To prevent automated spam submissions leave this field empty.');
  if (module_exists('locale')) {
    if ($lang_code == NULL) {
      global $locale;
      $lang_code = $locale;
    }
    $description = variable_get("spamicide_description_{$lang_code}", $default);
  }
  else {
    $description = variable_get('spamicide_description', $default);
  }
  return $description;
}