You are here

function ckeditor_video_form_ckeditor_admin_profile_form_alter in CKEditor Video 7

Implements hook_form_FORM_ID_alter() for ckeditor_admin_profile_form().

File

./ckeditor_video.module, line 30
Written by Henri MEDOT <henri.medot[AT]absyx[DOT]fr> http://www.absyx.fr

Code

function ckeditor_video_form_ckeditor_admin_profile_form_alter(&$form, &$form_state) {
  $form['ckeditor_upload_settings']['filebrowser_video'] = array(
    '#type' => 'select',
    '#title' => t('File browser type (Video dialog window)'),
    '#default_value' => !empty($profile->settings['filebrowser_video']) ? $profile->settings['filebrowser_video'] : 'none',
    '#options' => $form['ckeditor_upload_settings']['filebrowser_image']['#options'],
    '#description' => t('Select the file browser that you would like to use to upload videos.'),
  );
  if (isset($form['ckeditor_upload_settings']['UserFilesPath'])) {
    $form['ckeditor_upload_settings']['UserFilesPath']['#weight'] = 10;
  }
  if (isset($form['ckeditor_upload_settings']['UserFilesAbsolutePath'])) {
    $form['ckeditor_upload_settings']['UserFilesAbsolutePath']['#weight'] = 20;
  }
}