本文整理汇总了PHP中Translation::makeLanguage方法的典型用法代码示例。如果您正苦于以下问题:PHP Translation::makeLanguage方法的具体用法?PHP Translation::makeLanguage怎么用?PHP Translation::makeLanguage使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Translation
的用法示例。
在下文中一共展示了Translation::makeLanguage方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: Translation
freepbx::out("\t\tMerge from master to this branch failed");
freepbx::out("Module " . $module . " will not be tagged!");
continue;
}
freepbx::out("Done");
if ($stashable) {
$repo->apply_stash();
$repo->drop_stash();
}
freepbx::out("\tProcessing localizations...");
freepbx::outn("\t\tUpdating master localization...");
$translation = new Translation($repodir);
if (!preg_match('/(core|framework)$/i', $repodir)) {
//if no i18n folder then make an english one!
if (!file_exists($repodir . '/i18n')) {
$translation->makeLanguage("en_US");
}
//pray that this works..
$translation->update_i18n();
freepbx::out("Done");
foreach (glob($repodir . '/i18n/*', GLOB_ONLYDIR) as $langDir) {
$lang = basename($langDir);
freepbx::outn("\t\tUpdating individual localization for " . $lang);
$o = $translation->merge_i18n($lang);
freepbx::out($o);
}
} elseif (preg_match('/framework$/i', $repodir)) {
$translation->update_i18n_amp();
foreach (glob($repodir . '/amp_conf/htdocs/admin/i18n/*', GLOB_ONLYDIR) as $langDir) {
$lang = basename($langDir);
freepbx::outn("\t\tUpdating individual localization for " . $lang);
示例2: Translation
freepbx::out("Module " . $module . " will not be tagged!");
continue;
}
freepbx::out("Done");
if ($stashable) {
$repo->apply_stash();
$repo->drop_stash();
}
}
freepbx::out("\tProcessing localizations...");
freepbx::outn("\t\tUpdating master localization...");
$translation = new Translation($mod_dir);
if (!preg_match('/(core|framework)$/i', $mod_dir)) {
//if no i18n folder then make a spanish one!
if (!file_exists($mod_dir . '/i18n')) {
$translation->makeLanguage("es_ES");
}
//pray that this works..
$translation->update_i18n();
freepbx::out("Done");
foreach (glob($mod_dir . '/i18n/*', GLOB_ONLYDIR) as $langDir) {
$lang = basename($langDir);
freepbx::outn("\t\tUpdating individual localization for " . $lang);
$o = $translation->merge_i18n($lang);
freepbx::out($o);
}
} elseif (preg_match('/framework$/i', $mod_dir)) {
$translation->update_i18n_amp();
foreach (glob($mod_dir . '/amp_conf/htdocs/admin/i18n/*', GLOB_ONLYDIR) as $langDir) {
$lang = basename($langDir);
freepbx::outn("\t\tUpdating individual localization for " . $lang);