You are here

function l10_client_add_string_to_page in Localization client 6.2

Same name and namespace in other branches
  1. 6 l10n_client.module \l10_client_add_string_to_page()
  2. 7 l10n_client.module \l10_client_add_string_to_page()

Adds a string to the list onto the l10n_client UI on this page.

Parameters

$source: Source string or NULL if geting the list of strings specified.

$translation: Translation string. TRUE if untranslated.

$textgroup: Text group the string belongs to

2 calls to l10_client_add_string_to_page()
l10n_client_translate_page in ./l10n_client.module
Menu callback. Translation pages.
_l10n_client_page_strings in ./l10n_client.module
Get the strings to translate for this page.

File

./l10n_client.module, line 263
Localization client. Provides on-page translation editing.

Code

function l10_client_add_string_to_page($source = NULL, $translation = NULL, $textgroup = 'default') {
  static $strings = array();
  if (isset($source)) {
    $strings[$textgroup][$source] = $translation;
  }
  else {
    return $strings;
  }
}