public static function isLanguageEnabled($code)
    {
        if ($code == 'en') {
            return true;
        }

        $handle = (isset(self::$_languages[$code])) ? self::$_languages[$code]['handle'] : '';
        $enabled_extensions = array();

        // Fetch list of active extensions
        if (class_exists('Symphony', false) && (!is_null(Symphony::ExtensionManager()))) {
            $enabled_extensions = Symphony::ExtensionManager()->listInstalledHandles();
        }

        return in_array('lang_' . $handle, $enabled_extensions);
    }
public static function isLanguageEnabled($code)
    {
        if ($code == 'en') {
            return true;
        }

        $handle = (isset(self::$_languages[$code])) ? self::$_languages[$code]['handle'] : '';
        $enabled_extensions = array();

        // Fetch list of active extensions
        if (class_exists('Symphony', false) && (!is_null(Symphony::ExtensionManager()))) {
            $enabled_extensions = Symphony::ExtensionManager()->listInstalledHandles();
        }

        return in_array('lang_' . $handle, $enabled_extensions);
    }
public static function isLanguageEnabled ( $ code ) { if ( $ code == 'en' ) { return true ; } $ handle = ( isset ( self :: $ _languages [ $ code ] ) ) ? self :: $ _languages [ $ code ] [ 'handle' ] : '' ; $ enabled_extensions = array ( ) ; // Fetch list of active extensions if ( class_exists ( 'Symphony' , false ) && ( ! is_null ( Symphony :: ExtensionManager ( ) ) ) ) { $ enabled_extensions = Symphony :: ExtensionManager ( ) -> listInstalledHandles ( ) ; } return in_array ( 'lang_' . $ handle , $ enabled_extensions ) ; }
Given a valid language code, this function checks if the language is enabled.

@since Symphony 2.3
@param string $code
Language code, e. g. 'en' or 'pt-br'
@return boolean
If true, the language is enabled.
Given a valid language code this function checks if the language is enabled .