1 gettext.inc _locale_import_message($message, $file, $lineno = NULL)

Sets an error message if an error occurred during locale file parsing.

Parameters

$message: The message to be translated.

$file: Backdrop file object corresponding to the PO file to import.

$lineno: An optional line number argument.

Related topics

File

core/includes/gettext.inc, line 359
Gettext parsing and generating API.

Code

function _locale_import_message($message, $file, $lineno = NULL) {
  $vars = array('%filename' => $file->filename);
  if (isset($lineno)) {
    $vars['%line'] = $lineno;
  }
  $t = get_t();
  backdrop_set_message($t($message, $vars), 'error');
}