You are here

function video_multidownload_settings_form in Video 6

Same name and namespace in other branches
  1. 5 plugins/video_multidownload/video_multidownload.module \video_multidownload_settings_form()
  2. 6.2 plugins/video_multidownload/video_multidownload.module \video_multidownload_settings_form()

Implementation of hook_settings()

1 string reference to 'video_multidownload_settings_form'
video_multidownload_menu in plugins/video_multidownload/video_multidownload.module
Implementation of hook_menu().

File

plugins/video_multidownload/video_multidownload.module, line 98
Enable multiple file download in video module.

Code

function video_multidownload_settings_form() {
  $form = array();
  $options = array(
    1 => 'Yes',
    0 => 'No',
  );
  $form['multifile'] = array(
    '#type' => 'fieldset',
    '#title' => t('Multi-file download options'),
    '#description' => t('Allows a list of files to be shown on the download page. The list is usually gotten from a specified folder. This ability is useful for providing different sizes and video types for download.'),
  );
  $form['multifile']['video_multidownload'] = array(
    '#type' => 'radios',
    '#title' => t('Allow Multi-file Downloads'),
    '#options' => $options,
    '#default_value' => variable_get('video_multidownload', 0),
    '#description' => t('This feature can be disabled separately for each node. If turned on make sure you set the permissions so users can use this feature.') . ' ' . l(t('access control'), 'admin/access'),
  );
  $form['multifile']['video_download_ext'] = array(
    '#type' => 'textfield',
    '#title' => t('File extensions to show'),
    '#default_value' => variable_get('video_download_ext', 'mov,wmv,rm,flv,avi,divx,mpg,mpeg,mp4,zip'),
    '#description' => t('The extensions of files to list from the multi-file download folder on the download page. Extensions should be comma seperated with no spaces, for example (mov,wmv,rm).'),
  );
  return system_settings_form($form);
}