Add check for install_disabled file in language directories to avoid listing them during the installation if incomplete

Add text to invite people to contribute new translations if they cannot find theirs in the installer list - refs #7325
1.9.x
Yannick Warnier 10 years ago
parent da1bdf5425
commit 7e4c9281e2
  1. 11
      main/install/install.lib.php
  2. 0
      main/lang/faroese/install_disabled
  3. 0
      main/lang/tagalog/install_disabled
  4. 0
      main/lang/tibetan/install_disabled
  5. 0
      main/lang/xhosa/install_disabled

@ -381,6 +381,11 @@ function & get_language_folder_list() {
continue; continue;
} }
if (is_dir($dirname.$entries)) { if (is_dir($dirname.$entries)) {
if (is_file($dirname.$entries.'/install_disabled')) {
// Skip all languages that have this file present, just for
// the install process (languages incomplete)
continue;
}
$result[$entries] = ucwords(str_replace($search, $replace_with, $entries)); $result[$entries] = ucwords(str_replace($search, $replace_with, $entries));
} }
} }
@ -1029,7 +1034,7 @@ function display_language_selection_box($name = 'language_list', $default_langua
* can be done in the language of the user * can be done in the language of the user
*/ */
function display_language_selection() { ?> function display_language_selection() { ?>
<h2><?php get_lang('WelcomeToTheDokeosInstaller'); ?></h2> <h2><?php get_lang('WelcomeToTheChamiloInstaller'); ?></h2>
<div class="RequirementHeading"> <div class="RequirementHeading">
<h2><?php echo display_step_sequence(); ?><?php echo get_lang('InstallationLanguage'); ?></h2> <h2><?php echo display_step_sequence(); ?><?php echo get_lang('InstallationLanguage'); ?></h2>
<p><?php echo get_lang('PleaseSelectInstallationProcessLanguage'); ?>:</p> <p><?php echo get_lang('PleaseSelectInstallationProcessLanguage'); ?>:</p>
@ -1038,6 +1043,10 @@ function display_language_selection() { ?>
<button type="submit" name="step1" class="btn next" value="<?php echo get_lang('Next'); ?>"><?php echo get_lang('Next'); ?></button> <button type="submit" name="step1" class="btn next" value="<?php echo get_lang('Next'); ?>"><?php echo get_lang('Next'); ?></button>
<input type="hidden" name="is_executable" id="is_executable" value="-" /> <input type="hidden" name="is_executable" id="is_executable" value="-" />
</form> </form>
<br /><br />
</div>
<div class="RequirementHeading">
<?php echo get_lang('YourLanguageNotThereContactUs'); ?>
</div> </div>
<?php <?php
} }

Loading…
Cancel
Save