Instructions'; return $links; } if (!function_exists("afe_help_page")) { function afe_help_page() { add_options_page( 'Anywhere Flash Embed', 'Anywhere Flash Embed', 'manage_options', 'afe_help_page', 'afe_help_page_layout' ); } } /** * AFE function to initiate the global settings for the flash object * @param null * @return void **/ if (!function_exists('afe_setup_globals')) { function afe_setup_globals($atts) { global $afe; $afe = array( "css_class" => "afe-flash", "css_id" => "afe-swf-", "count" => 1, "swfs" => array() ); $afe = (object)$afe; } } /** * AFE function to initiate the help page * @param null * @return void **/ if (!function_exists("afe_help_page_layout")) { function afe_help_page_layout() { require_once('help-general.php'); } } /** * AFE function to initiate the flash object * @param null * @return void **/ function afe_init() { wp_enqueue_script("swfobject"); } add_action("init", "afe_init"); /** * AFE function hook into footer * @param null * @return void **/ function afe_wp_footer() { global $afe; echo ""; } add_action("wp_footer", "afe_wp_footer"); /** * AFE function to create the shortcode * @param null * @return void **/ if (!function_exists('afe_shortcode')) { function afe_shortcode($atts, $content = false) { global $afe; $args = shortcode_atts(array( "src" => false, "width" => false, "height" => false, "flashvars" => false, "params" => false, "version" => "9" ), $atts); extract($args); if (!$src || !$width || !$height) { return ""; } if ($params) { $args["params"] = wp_parse_args(html_entity_decode($params), false); } if ($flashvars) { $args["flashvars"] = wp_parse_args(html_entity_decode($flashvars), false); } $id = $afe->css_id . $afe->count; $afe->swfs[] = (object)array_merge($args, array( "replace_id" => $id )); $afe->count++; return "