/* Open Popup Starts */
function OpenPopUpWindow(url,width,height,scrollbars)
{	
	window.open(url,'',"width="+width+", height="+height+", scrollbars="+scrollbars+", screenX=100, screenY=100, location=0, resizable=0, status=1, toolbar=0, menubar=0", false);
}
/* Open Popup Ends */

/* get Twin Share Block Starts */
function getTwinShareBlock()
{
	var noofhead=document.bookdeparture.no_of_heads.value;
	if((noofhead%2)==0)
	{
		$("twin_share_div").style.display="none";
		document.bookdeparture.is_twin_share.checked=false;
	}
	else
	{
		$("twin_share_div").style.display="block";
		document.bookdeparture.is_twin_share.checked=false;
	}
}
/* get Twin Share Block Starts */

function popup(mylink, windowname)
{
if (! window.focus)return true;
var href;
if (typeof(mylink) == 'string')
   href=mylink;
else
   href=mylink.href;
   //window.resizeTo()
window.open(href, windowname, 'width=500,height=350,scrollbars=yes');
return false;
}

function resize(win,width,height)
{
if (parseInt(navigator.appVersion)>3)
  win.resizeTo(width,height+125);
}

/* Video Play Starts */

function PlayMediaDelayTime(clipName)
{	
	document.getElementById("player").innerHTML="";	
	document.getElementById("player").innerHTML='<object id="mediaPlayer" width="291" height="223" '
	+'classid="CLSID:22d6f312-b0f6-11d0-94ab-0080c74c7e95" '
	+'codebase="http://activex.microsoft.com/activex/controls/mplayer/en/nsmp2inf.cab#Version=5,1,52,701" '
	+'standby="Loading Microsoft Windows Media Player components..." type="application/x-oleobject">'
	+'<param name="fileName" value="">'
	+'<param name="autoStart" value="true">'
	+'<param name="showControls" value="true">'
	+'<param name="ShowStatusBar" value="1">'
	+'<param name="loop" value="false">'
	+'<embed type="application/x-mplayer2" '
	+'pluginspage="http://microsoft.com/windows/mediaplayer/en/download/" '
	+'showcontrols="true" width="291" height="223" '
	+'src="" autostart="true" loop="false">'
	+'</embed>'
	+'</object>';
	var func="PlayMedia('"+clipName+"')";
	var t=setTimeout(func,1000)
}

function PlayMedia(clipName)
{
	
document.getElementById("player").innerHTML="";	
document.getElementById("player").innerHTML='<object id="mediaPlayer" width="291" height="223" '
+'classid="CLSID:22d6f312-b0f6-11d0-94ab-0080c74c7e95" '
+'codebase="http://activex.microsoft.com/activex/controls/mplayer/en/nsmp2inf.cab#Version=5,1,52,701" '
+'standby="Loading Microsoft Windows Media Player components..." type="application/x-oleobject">'
+'<param name="fileName" value="'+clipName+'">'
+'<param name="autoStart" value="true">'
+'<param name="showControls" value="true">'
+'<param name="ShowStatusBar" value="1">'
+'<param name="loop" value="false">'
+'<embed type="application/x-mplayer2" '
+'pluginspage="http://microsoft.com/windows/mediaplayer/en/download/" '
+'showcontrols="true" width="291" height="223" '
+'src="'+clipName+'" autostart="true" loop="false">'
+'</embed>'
+'</object>';

}

/* Video Play Starts */