diff options
author | Angie Byron <webchick@24967.no-reply.drupal.org> | 2010-04-30 01:33:17 +0000 |
---|---|---|
committer | Angie Byron <webchick@24967.no-reply.drupal.org> | 2010-04-30 01:33:17 +0000 |
commit | a724915f82a0c25cabe60561cd9b4f7f72541734 (patch) | |
tree | 6601c55abe4005404aec5ef7f3aa94e74fd93411 /modules/system/system.admin.inc | |
parent | d97f4bdba3e29ea63f488e56f5141a203b7b2171 (diff) | |
download | brdo-a724915f82a0c25cabe60561cd9b4f7f72541734.tar.gz brdo-a724915f82a0c25cabe60561cd9b4f7f72541734.tar.bz2 |
#551658 by pwolanin, aaron, drewish: Move private files to an opt-in system, and no longer force private files to live within web-accessible directory.
Diffstat (limited to 'modules/system/system.admin.inc')
-rw-r--r-- | modules/system/system.admin.inc | 19 |
1 files changed, 11 insertions, 8 deletions
diff --git a/modules/system/system.admin.inc b/modules/system/system.admin.inc index 149b0819c..ec20138a1 100644 --- a/modules/system/system.admin.inc +++ b/modules/system/system.admin.inc @@ -1725,15 +1725,18 @@ function system_file_system_settings() { // Any visible, writeable wrapper can potentially be used for the files // directory, including a remote file system that integrates with a CDN. foreach(file_get_stream_wrappers(STREAM_WRAPPERS_WRITE_VISIBLE) as $scheme => $info) { - $options[$scheme] = $info['description']; + $options[$scheme] = check_plain($info['description']); + } + + if (!empty($options)) { + $form['file_default_scheme'] = array( + '#type' => 'radios', + '#title' => t('Default download method'), + '#default_value' => isset($options['public']) ? 'public' : key($options), + '#options' => $options, + '#description' => t('This setting is used as the preferred download method. The use of public files is more efficient, but does not provide any access control.'), + ); } - $form['file_default_scheme'] = array( - '#type' => 'radios', - '#title' => t('Default download method'), - '#default_value' => 'public', - '#options' => $options, - '#description' => t('This setting is used as the preferred download method. The use of public files is more efficient, but does not provide any access control.'), - ); return system_settings_form($form, TRUE); } |