} if (!$vdetails['embed_code'] || $vdetails['embed_code'] == 'none' || $ytcode) { $code = '<embed src="' . $embed_src . '" type="application/x-shockwave-flash"'; $code .= 'allowscriptaccess="always" allowfullscreen="true" '; $code .= 'width="' . config("embed_player_width") . '" height="' . config("embed_player_height") . '"></embed>'; return $code; } else { return false; } } /** * Writing CB Player function to play videos on facebook */ function cb_facebook_embed($params) { $vdetails = $params['video']; $config = urlencode(BASEURL . "/player/" . CB_PLAYER . "/embed_player.php?vid=" . $vdetails['videoid'] . "&autoplay=" . config('autoplay_embed')); $embed_src = BASEURL . '/player/' . CB_PLAYER . '/player.swf?config=' . $config; return $embed_src; } register_embed_function('cbplayer_embed_src'); register_actions_play_video('cb_player'); cb_register_function('cb_facebook_embed', 'fb_embed_video'); //include Pak Player JS File $Cbucket->add_header(CB_PLAYER_DIR . '/cbplayer_header.html'); $Cbucket->add_admin_header(CB_PLAYER_DIR . '/cbplayer_header.html'); /** * Including plugin files */ include "cbplayer.plugin.php"; }
* * @param video details * @return src link */ function pakplayer_embed_src($vdetails) { $config = urlencode(BASEURL . "/player/pak_player/embed_player.php?vid=" . $vdetails['videoid'] . "&json=true&autoplay=" . config('autoplay_embed')); if (!config('pak_license')) { $embed_src = BASEURL . '/player/pak_player/pakplayer.swf?config=' . $config; } else { $embed_src = BASEURL . '/player/pak_player/pakplayer.unlimited.swf?config=' . $config; } if (function_exists('get_refer_url_from_embed_code')) { $ref_details = get_refer_url_from_embed_code(unhtmlentities(stripslashes($vdetails['embed_code']))); $ytcode = $ref_details['ytcode']; } if (!$vdetails['embed_code'] || $vdetails['embed_code'] == 'none' || $ytcode) { $code = '<embed src="' . $embed_src . '" type="application/x-shockwave-flash"'; $code .= 'allowscriptaccess="always" allowfullscreen="true" '; $code .= 'width="' . config("embed_player_width") . '" height="' . config("embed_player_height") . '"></embed>'; return $code; } else { return false; } } register_embed_function('pakplayer_embed_src'); register_actions_play_video('pak_player'); //include Pak Player JS File $Cbucket->add_header(PAK_PLAYER_DIR . '/pplayer_head.html'); $Cbucket->add_admin_header(PAK_PLAYER_DIR . '/pplayer_head.html'); }