You are here

i18n_variable_hierarchy.module in Language Hierarchy 7

File

modules/i18n_variable_hierarchy/i18n_variable_hierarchy.module
View source
<?php

/**
 * Implements hook_language_init().
 */
function i18n_variable_hierarchy_language_init() {

  // Empty hook, just to ensure that this module is loaded on bootstrap so that
  // i18n_variable_hierarchy_variable_realm_info() will be invoked early enough.
}

/**
 * Implements hook_variable_realm_info().
 */
function i18n_variable_hierarchy_variable_realm_info() {
  $realm = array();

  // If someone has enabled the i18n_variable module, and change the controller.
  if (function_exists('i18n_variable_variable_realm_info')) {
    $realm['language'] = array(
      'controller class' => 'LanguageHierarchyI18nVariableLanguageRealm',
      'store class' => 'LanguageHierarchyI18nVariableStoreRealmStore',
    );
  }
  return $realm;
}