function hook_locale

7.x locale.api.php hook_locale($op = 'groups')
6.x core.php hook_locale($op = 'groups')

Allows modules to define their own text groups that can be translated.

Parameters

$op: Type of operation. Currently, only supports 'groups'.

Related topics

2 functions implement hook_locale()

Note: this list is generated by pattern matching, so it may include some functions that are not actually implementations of this hook.

install_select_locale in drupal-6.x/install.php
Allow admin to select which locale to use for the current profile.
locale_locale in drupal-6.x/modules/locale/locale.module
Implementation of hook_locale().
11 invocations of hook_locale()
locale_translate_export_pot_form in drupal-6.x/includes/locale.inc
Translation template export form.
locale_translate_export_po_form in drupal-6.x/includes/locale.inc
Form to export PO files for the languages provided.
locale_translate_import_form in drupal-6.x/includes/locale.inc
User interface for the translation import screen.
locale_translate_overview_screen in drupal-6.x/includes/locale.inc
Overview screen for translations.
locale_translate_seek_form in drupal-6.x/includes/locale.inc
User interface for the string search screen.

... See full list

File

documentation-6.x/developer/hooks/core.php, line 2730
These are the hooks that are invoked by the Drupal core.

Code

function hook_locale($op = 'groups') {
  switch ($op) {
    case 'groups':
      return array('custom' => t('Custom'));
  }
}