clipbucket/upload/player/jwplayer/jwplayer.php

57 lines
1.3 KiB
PHP
Raw Normal View History

2009-08-25 12:16:42 +00:00
<?php
/*
Player Name: JW Player Plugin
2009-08-27 15:01:32 +00:00
Description: jw Player for Clipbucket
2009-08-25 12:16:42 +00:00
Author: Arslan Hassan
ClipBucket Version: 2
Plugin Version: 1.0 - JW 4.5.230
Website: http://clip-bucket.com/
*/
/**
* This file is used to instruct ClipBucket
* for how to operate JW PLayer
* this file is protype
* you can get complete instructions
* from docs.clip-bucket.com
*
* @Author : Arslan Hassan
* @Script : ClipBucket v2
* @License : CBLA
* @Since : September 15 2009
*/
2009-08-25 12:16:42 +00:00
if(!function_exists(jw_player))
{
function jw_player($data)
2009-08-25 12:16:42 +00:00
{
$vdata = $data['vdetails'];
2009-08-25 12:16:42 +00:00
global $swfobj;
$vid_file = get_video_file($vdata,$no_video,false);
if($vid_file)
2009-08-25 12:16:42 +00:00
{
$swfobj->width = $data['width'];
$swfobj->height = $data['height'];
$swfobj->playerFile = PLAYER_URL.'/jwplayer/player.swf';
2009-08-25 12:16:42 +00:00
$swfobj->FlashObj();
//Writing Param
$swfobj->addParam('allowfullscreen','true');
$swfobj->addParam('allowscriptaccess','always');
$swfobj->addParam('wmode','opaque');
$swfobj->addVar('file',BASEURL.'/files/videos/'.$vid_file);
2009-08-25 12:16:42 +00:00
$swfobj->CreatePlayer();
return $swfobj->code;
}else
2009-08-25 12:16:42 +00:00
return false;
}
add_js(array('swfobject.obj.js'=>'global'));
2009-08-25 12:16:42 +00:00
register_actions_play_video('jw_player');
}
?>