'SESSIONS_LIMIT_ERROR', 116 => 'geoip error', 106 => 'cannot play', 114 => 'Registration / Subscription Required Subscribe here!', 115 => 'The content you are trying to view is only available to registered users who have purchased a subscription for this channel. If you are a registered user, please log in and purchase a subscription. If you are a new user, please register first.');
$vap = new visionAPIconnector();
if ($_SESSION['v247']['user']['session'])
{
$session = $_SESSION['v247']['user']['session'];
}else if ($_SESSION['v247']['guest']['session'])
{
$session = $_SESSION['v247']['guest']['session'];
}else
{
$resp = $vap->login('username', array('username'=>'freeviewGuest', 'portalid'=>101, 'password'=>'guest123'));
$res = explode('|', trim($resp, '$'));
$_SESSION['v247']['guest']['session'] = $res[1];
$session = $res[1];
}
$resp = $vap->itemAuth('itemid', array('extsessionid'=>$session, 'itemid'=>$_GET['vid']));
$res = explode('|', trim($resp, '$'));
if ($res[0] == "0")
{
$resp = $vap->getItemMetadata('itemid', array('itemid'=>$_GET['vid']));
$item = explode('|', trim($resp, '$'));
/*echo '
function playCurrent()
{
if (!playItem({$_GET['vid']}, '{$session}', '{$thumbnail}'))
{
setTimeout(playCurrent, 200);
}
}
playCurrent();
PLAYEREND;
}else
{
echo "
'; print_r($item); echo '';*/ $title = $item[1]; $rating = $item[2]; $distributor= $item[12]; $synopsis = $item[5]; $price = $item[17]; $director = $item[7]; $actors = $item[8]; $genre = $item[4]; $year = $item[9]; if ($item[3] == '') { $duration = '24h'; }else { $duration_h = floor($item[3]/86400); $duration_m = floor(($item[3] - $duration_h * 86400) / 3600); $duration_s = floor($item[3] - ($duration_h * 86400 + $duration_m * 3600)); $duration = $duration_h . ':' . $duration_m . ':' . $duration_s; } $thumbnail = $item[13]; $country = $item[10]; echo
->!--
This video will appear above shortly...
| |
|
{$title}{$synopsis} |
{$genre} | |
Overview
|
{$emessage[$res[0]]}
";
}
?>