From 69927fc15c744bd3602fe7d404af6a80130a1ce9 Mon Sep 17 00:00:00 2001 From: Heshan Date: Fri, 18 Mar 2011 00:13:45 +0530 Subject: Fixed the JS issues and Select players and trasncoders --- modules/video_ui/video.admin.inc | 26 +++++++++++++++++--------- 1 file changed, 17 insertions(+), 9 deletions(-) (limited to 'modules') diff --git a/modules/video_ui/video.admin.inc b/modules/video_ui/video.admin.inc index 32fc5e8..ed76a20 100644 --- a/modules/video_ui/video.admin.inc +++ b/modules/video_ui/video.admin.inc @@ -112,15 +112,23 @@ function video_players_admin_settings() { '#suffix' => '', ); - $form['extensions']['video_extension_' . $ext . '_flash_player'] = array( - '#type' => !empty($flv_players) ? 'radios' : 'markup', - '#title' => t('Flash Player for') . ' ' . $ext, - '#value' => !empty($flv_players) ? '' : t('No flash players detected.
You need to install !swf_tools or !flowplayer.', array('!swf_tools' => l(t('SWF Tools'), 'http://www.drupal.org/project/swftools'), '!flowplayer' => l(t('Flowplayer'), 'http://www.drupal.org/project/flowplayer'))), - '#options' => $flv_players, - '#default_value' => variable_get('video_extension_' . $ext . '_flash_player', ''), - '#prefix' => '
', - '#suffix' => '
', - ); + if (!empty($flv_players)) { + $form['extensions']['video_extension_' . $ext . '_flash_player'] = array( + '#type' => 'radios', + '#title' => t('Flash Player for') . ' ' . $ext, + '#options' => $flv_players, + '#default_value' => variable_get('video_extension_' . $ext . '_flash_player', ''), + '#prefix' => '
', + '#suffix' => '
', + ); + } else { + $form['extensions']['video_extension_' . $ext . '_flash_player'] = array( + '#type' => 'markup', + '#markup' => t('No flash players detected.
You need to install !swf_tools or !flowplayer.', array('!swf_tools' => l(t('SWF Tools'), 'http://www.drupal.org/project/swftools'), '!flowplayer' => l(t('Flowplayer'), 'http://www.drupal.org/project/flowplayer'))), + '#prefix' => '
', + '#suffix' => '
', + ); + } } return system_settings_form($form); } -- cgit v1.2.3