本文整理汇总了PHP中Translator::getReleaseData方法的典型用法代码示例。如果您正苦于以下问题:PHP Translator::getReleaseData方法的具体用法?PHP Translator::getReleaseData怎么用?PHP Translator::getReleaseData使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Translator
的用法示例。
在下文中一共展示了Translator::getReleaseData方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: header
break;
case 'p_install':
$translator->addRelease($_POST);
if ($_POST['id'] != 'current_installation') {
$translator->delete_directory(INSTALL_TEMP_DIR . session_id());
}
header('Location:index.php?cat=translator&module=main');
exit;
case 'mod':
$toolbar->icon_list['cancel']['params'] = 'onclick="location.href = \'' . html_href_link(FILENAME_DEFAULT, gen_get_all_get_params(array('action')) . 'action=releases', 'SSL') . '\'"';
$toolbar->icon_list['save']['show'] = true;
$toolbar->icon_list['save']['params'] = 'onclick="javascript:document.translator.submit()"';
$toolbar->icon_list['delete']['params'] = 'onclick="document.translator.action.value=\'p_delete\'; document.translator.submit()"';
$toolbar->icon_list['delete']['show'] = true;
$include_template = 'template_mod.php';
$release = $translator->getReleaseData($_GET['id']);
break;
case 'p_mod':
$translator->updateRelease($_POST);
header('Location:index.php?cat=translator&module=main');
exit;
case 'p_delete':
if (strstr($_POST['remove'], 'm_') !== false) {
$id = str_replace('m_', '', $_POST['remove']);
//exit;
$translator->deleteLangModule($id);
} else {
if (strstr($_POST['remove'], 'f_') !== false) {
$id = str_replace('f_', '', $_POST['remove']);
$translator->deleteLangFile($id);
}
示例2: Translator
$translator = new Translator('index', $db);
$replace = array();
// set some defaults for the toolbar
$toolbar->icon_list['cancel']['params'] = 'onclick="location.href = \'' . html_href_link(FILENAME_DEFAULT, '', 'SSL') . '\'"';
$toolbar->icon_list['open']['show'] = false;
$toolbar->icon_list['delete']['show'] = false;
$toolbar->icon_list['save']['show'] = false;
$toolbar->icon_list['print']['show'] = false;
// END OF HEADER
switch ($action) {
default:
case 'p_files':
case 'files':
$toolbar->icon_list['cancel']['params'] = 'onclick="location.href = \'' . html_href_link(FILENAME_DEFAULT, gen_get_all_get_params(array('action')) . 'module=main&action=releases', 'SSL') . '\'"';
$include_template = 'template_files.php';
$release = $translator->getReleaseData($_REQUEST['id']);
$files = $translator->getFilesForRelease($_REQUEST['id'], $_REQUEST['modules']);
break;
case 'p_translate':
$translator->updateTranslationStrings($_POST);
case 'p_search':
case 'translate':
$toolbar->icon_list['cancel']['params'] = 'onclick="location.href = \'' . html_href_link(FILENAME_DEFAULT, gen_get_all_get_params(array('action')) . 'module=files&action=files&id=' . $_REQUEST['release'], 'SSL') . '\'"';
$toolbar->icon_list['save']['show'] = true;
$toolbar->icon_list['save']['params'] = 'onclick="javascript:document.translator.submit()"';
$include_template = 'template_translate.php';
$translations = $translator->getStringsToTranslateForFile($_REQUEST['id'], $_REQUEST['defined_key'], $_REQUEST['original'], $_REQUEST['translation'], $_REQUEST['translated']);
break;
}
/***************** prepare to display templates *************************/
$include_header = true;