add_translation_source

Translation-related functions

Summary

add_translation_source(string $dir)

Add an translation source directory.

The directory’s contents should be .mo files following the naming scheme ofOmeka’s application/languages directory. If a .mo for the current localeexists, the translations will be loaded.

Parameters:
  • $dir (string) – Directory from which to load translations.

Usage

Examples

<?php

function exhibit_builder_initialize()
{
    add_translation_source(dirname(__FILE__) . '/languages');
}

?>

See Also