You are here

function brightcove_media_browser_filter_form in Brightcove Video Connect 7.2

Same name and namespace in other branches
  1. 7.7 brightcove_media/brightcove_media.module \brightcove_media_browser_filter_form()
  2. 7.3 brightcove_media/brightcove_media.module \brightcove_media_browser_filter_form()
  3. 7.4 brightcove_media/brightcove_media.module \brightcove_media_browser_filter_form()
  4. 7.6 brightcove_media/brightcove_media.module \brightcove_media_browser_filter_form()

Filter form for brightcove media video browser.

1 string reference to 'brightcove_media_browser_filter_form'
brightcove_media_media_browser_plugin_view in brightcove_media/brightcove_media.module
Implements hook_media_browser_plugin_view().

File

brightcove_media/brightcove_media.module, line 306

Code

function brightcove_media_browser_filter_form($form, &$form_state) {
  $form['searchform'] = array(
    '#type' => 'fieldset',
    '#title' => t('Filter videos'),
    '#collapsible' => TRUE,
    '#collapsed' => TRUE,
  );
  $keywords = '';
  $form['searchform']['keywords'] = array(
    '#type' => 'textfield',
    '#title' => t('Keywords'),
    '#size' => 25,
    '#default_value' => $keywords,
    '#description' => t('Comma separated keywords to search for. (do not add space after comma)'),
  );
  $form['searchform']['search'] = array(
    '#type' => 'radios',
    '#title' => t('Search in'),
    '#options' => array(
      'name' => t('Names and descriptions'),
      'tags' => t('Tags: at least one of these'),
      'and_tags' => t('Tags: all of these'),
    ),
    '#default_value' => 'name',
    '#attributes' => array(
      'class' => array(
        'search-radio',
      ),
    ),
    '#description' => t('"Names and descriptions" searches in Video name, short and long descriptions. Tags searches in Video associated tags.'),
  );
  $form['searchform']['filter'] = array(
    '#type' => 'button',
    '#name' => 'filter',
    '#value' => t('Filter'),
  );
  $form['searchform']['reset'] = array(
    '#type' => 'button',
    '#name' => 'reset',
    '#value' => t('Reset'),
  );
  $form['#prefix'] = '<div id="bc-filter-form">';
  $form['#suffix'] = '</div>';
  return $form;
}