diff options
Diffstat (limited to 'includes/install.inc')
-rw-r--r-- | includes/install.inc | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/includes/install.inc b/includes/install.inc index 11b1a35c2..23a7137b8 100644 --- a/includes/install.inc +++ b/includes/install.inc @@ -849,10 +849,14 @@ function install_goto($path) { * @see t() * @ingroup sanitization */ -function st($string, $args = array()) { +function st($string, array $args = array(), array $options = array()) { static $locale_strings = NULL; global $install_state; + if (empty($options['context'])) { + $options['context'] = ''; + } + if (!isset($locale_strings)) { $locale_strings = array(); if (isset($install_state['parameters']['profile']) && isset($install_state['parameters']['locale'])) { @@ -883,7 +887,7 @@ function st($string, $args = array()) { case '!': } } - return strtr((!empty($locale_strings[$string]) ? $locale_strings[$string] : $string), $args); + return strtr((!empty($locale_strings[$options['context']][$string]) ? $locale_strings[$options['context']][$string] : $string), $args); } /** |