Function __global->translate_text
Definitions
sources/translation.php
- Translate some text.
- Is abstract?: No
- Is static?: No
- Is final?: No
- Return: string
Parameters
Name | Type | Default | Set | Range | Description |
---|---|---|---|---|---|
$text | string | required parameter | N/A | N/A | The text to translate |
$context | integer | 0 | N/A | N/A | A TRANS_TEXT_CONTEXT_* constant |
$from | ?LANGUAGE_NAME | Null | N/A | N/A | Source language (null: autodetect from the text itself) |
$to | ?LANGUAGE_NAME | Null | N/A | N/A | Destination language (null: current user's language) |
$hook | ?string | Null | N/A | N/A | Specific hook to use (null: first that'll do it) |
$errormsg | ?string | Null | N/A | N/A | Error message (returned by reference) (null: not set yet) |
Return
- Translated text (null: some kind of error)
- Type: ?string
- Set: N/A
- Range: N/A