Projet

Général

Profil

Paste
Statistiques
| Branche: | Révision:

root / drupal7 / sites / all / modules / i18n / i18n_translation @ 9faa5de0

Nom Taille Révision Âge Auteur Commentaire
README.txt 1,48 ko 9faa5de0 presque 3 ans Assos Assos Weekly update of contrib modules
i18n_translation.admin.inc 3,09 ko f7a2490e environ 10 ans Assos Assos git mv htmltest drupal7
i18n_translation.api.php 1,63 ko f7a2490e environ 10 ans Assos Assos git mv htmltest drupal7
i18n_translation.inc 12,5 ko f7a2490e environ 10 ans Assos Assos git mv htmltest drupal7
i18n_translation.info 339 octets 9faa5de0 presque 3 ans Assos Assos Weekly update of contrib modules
i18n_translation.install 2,1 ko f7a2490e environ 10 ans Assos Assos git mv htmltest drupal7
i18n_translation.module 10,9 ko 8c72e82a environ 7 ans Assos Assos Weekly update of contrib modules
i18n_translation.pages.inc 292 octets f7a2490e environ 10 ans Assos Assos git mv htmltest drupal7

Dernières révisions

# Date Auteur Commentaire
9faa5de0 28/04/2021 23:11 Assos Assos

Weekly update of contrib modules

d50a36e0 17/06/2020 23:12 Assos Assos

Weekly update of contrib modules

3115e37e 23/08/2018 01:23 Assos Assos

Weekly update of contrib modules

2157f5a8 12/07/2018 00:20 Assos Assos

Weekly update of contrib modules

01f36513 26/04/2018 04:18 Assos Assos

Weekly update of contrib modules

e0d35157 30/11/2017 00:06 Assos Assos

Weekly update of contrib modules

e013fa40 22/06/2017 00:07 Assos Assos

Weekly update of contrib modules

8c72e82a 20/04/2017 00:04 Assos Assos

Weekly update of contrib modules

b3ab3446 02/02/2017 00:03 Assos Assos

Weekly update of contrib modules

fc3d89c3 26/10/2016 22:44 Assos Assos

Weekly update of contrib modules

Voir les révisions

README


README.txt

Drupal module: Translation set API

This is a generic API to handle translation sets. It is being used for now
for path translation and taxonomy term translation inside i18n package.

Translation sets can hold a collection of entities or other objects. A translation set is itself
an Entity thus leveraging all the power of the Entity API.

It also provides some basic storage for translation sets and a generator of new translation set id.
However, each module is responsible for storing which objects belong to which translation set for which
it needs to override some methods of the base i18n_translation_set class.

  • load_translations()
  • save_translations()
  • clean_translations()
  • delete_translations()

Once these are implemented, to get the objects belonging to a translation set, indexed by language code,
you can invoke this method on a translation set object:

  • get_translations()

To define a new type of translation set, a module must implement hook_i18n_translation_set_info()
as in this example:

/**

  • Implements hook_i18n_translation_set_info(). */ function i18n_path_i18n_translation_set_info() { return array( 'path' => array( 'title' => t('Paths'), 'class' => 'i18n_path_translation_set', ) ); }

See examples of overriding and extending this API:

  • i18n_path/i18n_path.inc
  • i18n_taxonomy/i18n_taxonomy.inc

====================================================================
Jose A. Reyero, http://reyero.net

Formats disponibles : Atom