Agile Player Settings Screen

The values set here will be the default values for all videos, unless you specify differently in the shortcode. Uncheck Use CDN hosted version? if you want to use a self-hosted copy of Agile Player instead of the CDN hosted version. Using the CDN hosted version is preferable in most situations.

If you are using a responsive WordPress theme, you may want to check the Responsive Video checkbox.

Uncheck the Use the [video] shortcode? option only if you are using WordPress 3.6+ and wish to use the [video] tag for MediaElement.js. You will still be able to use the [agileplayer] tag to embed videos using Agile Player.

_end_; } return $contextual_help; } add_filter('contextual_help', 'agileplayer_help', 10, 3); function agileplayer_settings() { if (!current_user_can('manage_options')) { wp_die( __('You do not have sufficient permissions to access this page.') ); } ?>

Agile Player Settings

Using Agile Player

"; } function width_output() { $options = get_option('agileplayer_options'); echo ""; } function preload_output() { $options = get_option('agileplayer_options'); if($options['agileplayer_preload']) { $checked = ' checked="checked" '; } else { $checked = ''; } echo ""; } function autoplay_output() { $options = get_option('agileplayer_options'); if($options['agileplayer_autoplay']) { $checked = ' checked="checked" '; } else { $checked = ''; } echo ""; } function responsive_output() { $options = get_option('agileplayer_options'); if($options['agileplayer_responsive']) { $checked = ' checked="checked" '; } else { $checked = ''; } echo ""; } function cdn_output() { $options = get_option('agileplayer_options'); if($options['agileplayer_cdn']) { $checked = ' checked="checked" '; } else { $checked = ''; } echo ""; } function color_one_output() { $options = get_option('agileplayer_options'); echo ""; } function color_two_output() { $options = get_option('agileplayer_options'); echo ""; } function color_three_output() { $options = get_option('agileplayer_options'); echo ""; } function video_shortcode_output() { $options = get_option('agileplayer_options'); if(array_key_exists('agileplayer_video_shortcode', $options)){ if($options['agileplayer_video_shortcode']) { $checked = ' checked="checked" '; } else { $checked = ''; } } else { $checked = ' checked="checked" '; } echo ""; } function reset_output() { $options = get_option('agileplayer_options'); if($options['agileplayer_reset']) { $checked = ' checked="checked" '; } else { $checked = ''; } echo ""; } /* Set Defaults */ register_activation_hook(plugin_dir_path( __FILE__ ) . 'app.php', 'add_defaults_fn'); function add_defaults_fn() { $tmp = get_option('agileplayer_options'); if(($tmp['agileplayer_reset']=='on')||(!is_array($tmp))) { $arr = array("agileplayer_height"=>"264","agileplayer_width"=>"640","agileplayer_preload"=>"","agileplayer_autoplay"=>"","agileplayer_responsive"=>"","agileplayer_cdn"=>"on","agileplayer_color_one"=>"#ccc","agileplayer_color_two"=>"#66A8CC","agileplayer_color_three"=>"#000","agileplayer_video_shortcode"=>"on","agileplayer_reset"=>""); update_option('agileplayer_options', $arr); update_option("agileplayer_db_version", "1.0"); } } /* Plugin Updater */ function update_agileplayer() { $agileplayer_db_version = "1.0"; if( get_option("agileplayer_db_version") != $agileplayer_db_version ) { //We need to update our database options $options = get_option('agileplayer_options'); //Set the new options to their defaults $options['agileplayer_color_one'] = "#ccc"; $options['agileplayer_color_two'] = "#66A8CC"; $options['agileplayer_color_three'] = "#000"; $options['agileplayer_video_shortcode'] = "on"; update_option('agileplayer_options', $options); update_option("agileplayer_db_version", $agileplayer_db_version); //Update the database version setting } } add_action('admin_init', 'update_agileplayer'); ?>