public static function Lingotek::isSupportedLanguage in Lingotek Translation 7.3
Same name and namespace in other branches
- 7.7 lib/Drupal/lingotek/Lingotek.php \Lingotek::isSupportedLanguage()
- 7.4 lib/Drupal/lingotek/Lingotek.php \Lingotek::isSupportedLanguage()
- 7.5 lib/Drupal/lingotek/Lingotek.php \Lingotek::isSupportedLanguage()
- 7.6 lib/Drupal/lingotek/Lingotek.php \Lingotek::isSupportedLanguage()
Returns whether the given language is supported.
Return value
Boolean value.
4 calls to Lingotek::isSupportedLanguage()
- lingotek_access in ./
lingotek.util.inc - Menu access callback.
- lingotek_node_view in ./
lingotek.module - Implements hook_node_view().
- lingotek_pm in ./
lingotek.page.inc - Page callback for the Lingotek local task on node detail pages.
- lingotek_upload_document in ./
lingotek.module
File
- lib/
Drupal/ lingotek/ Lingotek.php, line 345 - Defines Lingotek.
Class
- Lingotek
- A utility class for Lingotek translation.
Code
public static function isSupportedLanguage($drupal_language_code, $enabled = TRUE) {
//($drupal_language_code != LANGUAGE_NONE)
$supported = self::convertDrupal2Lingotek($drupal_language_code, $enabled) !== FALSE;
if (!$supported) {
LingotekLog::warning("Unsupported language detected: [@language]", array(
'@language' => $drupal_language_code,
));
}
return $supported;
}