function _locale_import_message

Sets an error message occurred during locale file parsing.

Parameters

$message: The message to be translated.

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

$lineno: An optional line number argument.

Related topics

1 call to _locale_import_message()
_locale_import_read_po in includes/locale.inc
Parses Gettext Portable Object file into an array

File

includes/locale.inc, line 987

Code

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

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.