2 /****************************************************************/
4 /****************************************************************/
5 /* Copyright (c) 2002-2010 */
6 /* Inclusive Design Institute */
9 /* This program is free software. You can redistribute it and/or*/
10 /* modify it under the terms of the GNU General Public License */
11 /* as published by the Free Software Foundation. */
12 /****************************************************************/
15 define('AT_INCLUDE_PATH', '../../../include/');
16 require(AT_INCLUDE_PATH.'vitals.inc.php');
17 admin_authenticate(AT_ADMIN_PRIV_LANGUAGES);
19 if (isset($_POST['svn_submit'])) {
20 $languageManager->liveImport($addslashes($_POST['import_lang']));
21 header('Location: '.$_SERVER['PHP_SELF']);
25 require(AT_INCLUDE_PATH.'header.inc.php');
29 if (!defined('AT_DEVEL_TRANSLATE') || !AT_DEVEL_TRANSLATE) {
30 $button_state = 'disabled="disabled"';
36 <div class="input-form">
38 <h3><?php echo _AT('translate'); ?></h3>
42 <p><?php echo _AT('translate_lang_howto'); ?></p>
45 <div class="row buttons">
46 <input type="button" onclick="javascript:window.open('<?php echo AT_BASE_HREF; ?>mods/_core/languages/translate_atutor.php', 'newWin1', 'toolbar=0, location=0, directories=0, status=0, menubar=0, scrollbars=1, resizable=1, copyhistory=0, width=640, height=480')" value="<?php echo _AT('translate'); ?>" <?php echo $button_state; ?> />
51 <?php if (defined('AT_DEVEL_TRANSLATE') && AT_DEVEL_TRANSLATE): ?>
52 <form name="form1" method="post" action="mods/_core/languages/language_translate.php">
53 <div class="input-form">
55 Import partial language from the <strong>live ATutor language database</strong> to your local installation for translating.
59 require_once(AT_INCLUDE_PATH.'../mods/_core/languages/classes/RemoteLanguageManager.class.php');
60 $remoteLanguageManager = new RemoteLanguageManager();
61 $remoteLanguageManager->printDropdown($_SESSION['lang'], 'import_lang', 'import_lang');
65 <div class="row buttons">
66 <input type="submit" name="svn_submit" value="<?php echo _AT('import'); ?>" />
72 <?php require(AT_INCLUDE_PATH.'footer.inc.php'); ?>