﻿function SearchBoxHandler(defaultText){if(typeof(searchKey)!='undefined'&&searchKey!="")defaultText=searchKey;$("#SearchBox input.SearchInput").attr("value",defaultText);$("#SearchBox input.SearchInput").focus(function(){this.value="";});$("#SearchBox input.SearchInput").blur(function(){if(this.value=="")this.value=defaultText;});$("#txtUsername").bind("focus",function(){if(this.value.indexOf("Email or Smartcard No")>-1)this.value="";}).bind("blur",function(){if(this.value=="")
this.value="Email or Smartcard No:";});$("#UCLogin_txtUsername").bind("focus",function(){if(this.value.indexOf("Email or Smartcard No")>-1)this.value="";}).bind("blur",function(){if(this.value=="")
this.value="Email or Smartcard No:";});}
function SearchBoxHandlerArabic(defaultText){if(typeof(searchKey)!='undefined'&&searchKey!="")defaultText=searchKey;$("#SearchBox input.SearchInputAr").attr("value",defaultText);$("#SearchBox input.SearchInputAr").focus(function(){this.value="";});$("#SearchBox input.SearchInputAr").blur(function(){if(this.value=="")this.value=defaultText;});}
function tabHandler(){$("#SearchBox label:eq(0)").click(function(){$("#SearchBox li:eq(0)").addClass("Active");$("#SearchBox li:eq(1)").removeClass("Active");$("#Site").attr("checked","checked");});$("#SearchBox label:eq(1)").click(function(){$("#SearchBox li:eq(1)").addClass("Active");$("#SearchBox li:eq(0)").removeClass("Active");$("#Programmes").attr("checked","checked");});}
function LoginHandler(){var b=new Proximity.Browser();$("#Login a").bind("mouseover",function(){$("div",this.parentNode).css("display","block");if($("#LoginFrame").attr("name")==null||$("#LoginFrame").attr("name")==""){$("#LoginFrame").attr("name","LoginName");$("#LoginFrame").attr("src","/MyShowtime/Login/$Bubble_"+currentPageLocale+".aspx");}
$("div",this.parentNode).append("<span class='Close'> </span>");$("div span",this.parentNode).bind("click",function(){$("#Login div").css("display","none");}).bind("mouseover",function(){$(this).css("color","#ff0000");}).bind("mouseout",function(){$(this).css("color","#ffffff");});});if($("#Login")){$("#SearchBox fieldset").css("top","40px");}}
function MustSeeTvHandler(){$("#Schedule > ul > li > a").bind("click",function(){$("#Schedule ul li").removeClass("Active");$("#Schedule > ul > li > ul").css("display","none");$(this).parent().addClass("Active");$(this).parent().find("ul").css("display","block");});}
function RedirectURL(URL)
{location.href=URL;}
function SelectOnChangeRedirect(URL)
{location.href=URL.value;}
function formatHtmlForXml(html)
{var xml=html;var xmlTag;var xmlTagNameLength;xml=xml.replace(/[\r\n\s]+/gi," ");xml=xml.replace(/ *([<>]) */gi,"$1");xml=xml.replace(/<img([^>]+)[ \/]*>+/gi,"<img$1 />");xml=xml.replace(/( [\w]+)=([^"^ ^>]+)/gi,"$1=\"$2\"");xmlTag=xml.split("<");xml="";for(var i=1;i<xmlTag.length;i++)
{xmlTagNameLength=Math.min(Math.max(xmlTag[i].indexOf(" "),xmlTag[i].length),xmlTag[i].indexOf(">"));if(xmlTagNameLength>0)
{xml+=("<"+xmlTag[i].substr(0,xmlTagNameLength).toLowerCase()+xmlTag[i].substr(xmlTagNameLength));}
else
{xml+=("<"+xmlTag[i]);}}
return(xml);}
function countImmediateElements(n,tagName){if(n){var LIs=n.getElementsByTagName(tagName);var childs=0;for(var i=0;i<LIs.length;i++){if(LIs[i].parentNode==LIs[0].parentNode)childs+=1;}
return childs;}}
function fixSelectBug(){var thisID=ip$.getID("Navigation1");if(thisID){var sfULs=thisID.getElementsByTagName("UL");var selEls=document.getElementsByTagName("SELECT");var b=new Proximity.Browser();if(b.isIE6()&&selEls[0]){for(var i=0;i<sfULs.length;i++){var ieMat=document.createElement("iframe");ieMat.filter="mask()";ieMat.setAttribute("frameborder","0");ieMat.setAttribute("src","about:blank");ieMat.style.borderWidth="0px";ieMat.style.height=(countImmediateElements(sfULs[i],"LI")*25)-10+"px";sfULs[i].getElementsByTagName("LI")[0].appendChild(ieMat);}}}
var thisID=ip$.getID("Navigation3");if(thisID){var sfULs=thisID.getElementsByTagName("UL");var selEls=document.getElementsByTagName("SELECT");var b=new Proximity.Browser();if(b.isIE6()&&selEls[0]){for(var i=0;i<sfULs.length;i++){var ieMat=document.createElement("iframe");ieMat.filter="mask()";ieMat.setAttribute("frameborder","0");ieMat.setAttribute("src","about:blank");ieMat.style.borderWidth="0px";ieMat.style.height=(countImmediateElements(sfULs[i],"LI")*21)-10+"px";sfULs[i].getElementsByTagName("LI")[0].appendChild(ieMat);}}}}
function toggleBlockVisibility(objID){if(objID.style.display=="none")
{objID.style.display="block";}
else
{objID.style.display="none";}}
function inputFilterHandler(){var disableInputs=ip$.getClass(document,"Disable");var digitInputs=ip$.getClass(document,"Digit");var alphaNumerics=ip$.getClass(document,"AlphaNumerics");for(var i=0;i<disableInputs.length;i++){if(disableInputs[i].tagName=="INPUT"){disableInputs[i].onkeydown=function(e){var code;if(!e)var e=window.event;if(e.keyCode)code=e.keyCode;code=e.charCode?e.charCode:e.keyCode;var acceptedCode=(code==9||code==16||code==36||code==37||code==39);if(acceptedCode)return true;else return false;}}}
for(var i=0;i<digitInputs.length;i++){if(digitInputs[i].tagName=="INPUT"){digitInputs[i].onkeypress=function(e){var code;if(!e)var e=window.event;code=e.charCode?e.charCode:e.keyCode;var acceptedCode=(code>47&&code<58);acceptedCode=acceptedCode||code==32||code==8||code==9||code==16||code==36||code==37||code==39||code==46;if(acceptedCode)return true;else{var loc=window.location.toString();var msgAr="يرجى إستعمال الأرقام فقط.";var msgEn="Only numbers allowed.";if(loc.indexOf("en_gb")>-1){alert(msgEn);}
else{alert(msgAr);}
return false;}}}}
for(var i=0;i<alphaNumerics.length;i++){if(alphaNumerics[i].tagName=="INPUT"){alphaNumerics[i].onkeypress=function(e){var code;if(!e)var e=window.event;code=e.charCode?e.charCode:e.keyCode;var acceptedCode=(code>47&&code<59);acceptedCode=acceptedCode||(code>96&&code<123);acceptedCode=acceptedCode||(code>64&&code<91);acceptedCode=acceptedCode||code==32||code==8||code==9||code==16||code==36||code==37||code==39||code==46;acceptedCode=acceptedCode||code==64;if(acceptedCode)return true;else{var loc=window.location.toString();var msgAr="يرجى إستعمال الأحرف الإنجليزية أو الأرقام فقط.";var msgEn="Only numbers and letters allowed.";if(loc.indexOf("en_gb")>-1){alert(msgEn);}
else{alert(msgAr);}
return false;}}}}}
function OfferRotator(){var rotator=ip$.getID("OfferRotator");if(rotator){hideAllOffers();var offers=rotator.getElementsByTagName("LI");offers[0].style.display="block";var previous=ip$.getID("Previous");var next=ip$.getID("Next");if(previous&&next){previous.style.display="block";next.style.display="block";previous.onclick=function(){var rotator=ip$.getID("OfferRotator");var offers=rotator.getElementsByTagName("LI");var temp=getOfferIndex();hideAllOffers();temp--;if(temp<0)temp=offers.length-1;offers[temp].style.display="block";return false;}
next.onclick=function(){var rotator=ip$.getID("OfferRotator");var offers=rotator.getElementsByTagName("LI");var temp=getOfferIndex();hideAllOffers();temp++;if(temp>=offers.length)temp=0;offers[temp].style.display="block";return false;}}}}
function hideAllOffers(){var rotator=ip$.getID("OfferRotator");if(rotator){var offers=rotator.getElementsByTagName("LI");for(var i=0;i<offers.length;i++){offers[i].style.display="none";}}}
function getOfferIndex(){var rotator=ip$.getID("OfferRotator");if(rotator){var offers=rotator.getElementsByTagName("LI");for(var i=0;i<offers.length;i++){if(offers[i].style.display=="block")return i;}}}
function invoicesHandler(){var invoiceThumb=ip$.getID("Invoices");var invoiceList=ip$.getID("InvoiceList");if(invoiceThumb&&invoiceList){toggleInvoice(0);var invoices=invoiceThumb.getElementsByTagName("LI");for(var i=0;i<invoices.length;i++){invoices[i].onclick=function(i){var invoiceThumb=ip$.getID("Invoices");var invoices=invoiceThumb.getElementsByTagName("LI");var invoice=0;for(var i=0;i<invoices.length;i++){invoices[i].className=invoices[i].className.replace("Active","");if(invoices[i]==this)invoice=i;}
this.className+=" Active";toggleInvoice(invoice);}}}}
function toggleInvoice(shownInvoice){var invoice=ip$.getID("InvoiceList");if(invoice){var invoices=invoice.getElementsByTagName("LI");for(var i=0;i<invoices.length;i++){invoices[i].style.display="none";if(shownInvoice==i)invoices[i].style.display="block";}}}
function hideFlashNav(){$("#Navigation").css("z-index","0");showSelectInput();}
function showFlashNav(){$("#Navigation").css("z-index","100");hideSelectInput();}
function faqHandler(){$("div.Faq div").hide();$("div.Faq li a").bind("click",function(){$("div",this.parentNode).toggle("fast");return false;});}
function SubscribeHandler(){if(typeof(SubscribeHandler2)!="undefined")SubscribeHandler2();}
function ShowGuideHandler(){var progCal=document.getElementById("ProgramCalendar");if(progCal){var As=progCal.getElementsByTagName("A");for(var i=0;i<As.length;i++){if(As[i].offsetHeight-24>11){var x=Math.floor((As[i].offsetHeight-35)/2)*-1;As[i].style.marginTop=x+"px";}}}}
function hideSelectInput(){var b=new Proximity.Browser();if(b.isIE6()){$("select").css("visibility","hidden");}}
function showSelectInput(){var b=new Proximity.Browser();if(b.isIE6()){$("select").css("visibility","visible");}}
function AtoZlist(){$("#TLlist li").bind("click",function(){$("#TLlist li").removeClass("Active");$(this).addClass("Active");});}
function RenewContract(){$("#RenewContract_ContractLength").bind("change",function(){var choice=$(this).attr("value");if(choice==6){$("#RenewContract_PaymentFrequency").html("<option value=\"6\">In Advance</option>");}
else{$("#RenewContract_PaymentFrequency").html("<option value=\"1\">Monthly</option><option value=\"12\">In Advance</option>");}});}
function STSHandler(){$("div.STSVenue li").bind("click",function(){$("div.STSVenue li").removeClass("Active");$("div.STSVenue li img").each(function(){this.src=this.src.replace("Active","");});$(this).addClass("Active");var imgSrc=$("img",this).attr("src");imgSrc=imgSrc.replace(".gif","Active.gif");$("img",this).attr("src",imgSrc);$("div.Entrants > ul > li").removeClass("Active");}).each(function(i){$(this).bind("click",function(){$("div.Entrants > ul > li").eq(i).addClass("Active");});});}
function FixFirefoxMac(){var b=new Proximity.Browser();if(b.isFirefox()&&b.isMac()){$("#Navigation").css("position","static");$("#Content").css("position","static");}
if(b.isNetscape()&&parseInt(b.getVersion())==7){$("#LoginPanel div.Form").css("text-align","inherit");$("#Navigation2 li a").css({"display":"inline","float":"right"});$("div.PackageBox fieldset.Action a[@href=#]").css("display","none");$("ul.Breadcrumb").css("width","auto");$("input.Text1").css("height","18px");}}
var currentTickerIndex=0;var timeOutId=null;function Ticker(){alert("inside");var y=ip$.getID("Ticker");if(y)x=y.getElementsByTagName("LI");if(x.length){if(currentTickerIndex>x.length-1)currentTickerIndex=0;for(var i=0;i<x.length;i++){x[i].style.display='none';}
x[currentTickerIndex].style.display='block';timeOutId=window.setTimeout("Ticker()",5000);$("#Ticker li:visible").fadeIn(500);$("#Ticker li:visible").fadeTo(2000,100);$("#Ticker li:visible").fadeOut(2500);currentTickerIndex++;}}
function TickerHandler(){$("#Ticker ul").after("<span id='MaskTicker'></span>");$("#MaskTicker").css("display","none");$("#Ticker ul").mouseover(function(){var currentLine=$("#Ticker li:visible").html();$("#MaskTicker").html(currentLine);$("#MaskTicker").css("display","block");});$("#MaskTicker").mouseout(function(){$("#MaskTicker").css("display","none");});}
function TrailerHandler(){if(currentPageLocale=="en_gb")
{$("#TLtrailers li a").bind('click',function(){$("#TLtrailers li a").not(this).html("Watch The Trailer").css({color:'#666666'});if($(this).html().indexOf("Now Showing")>-1)return false;$(this).html("Now Showing").css({color:'#c80000'});});}
if(currentPageLocale=="ar_ae"){$("#TLtrailers li a").bind('click',function(){$("#TLtrailers li a").not(this).html("شاهد العرض القادم").css({color:'#666666'});if($(this).html().indexOf("العرض المقبل")>-1)return false;$(this).html("العرض المقبل").css({color:'#c80000'});});}}
function OnlinePoll(){var vote=$("div.OnlinePoll input.Red34x17");var viewresult=$("div.OnlinePoll input.Grey80x17");viewresult.bind('click',function(){$("div.OnlinePoll fieldset.Choices").fadeOut(1000);$(this).fadeOut(1000);vote.fadeOut(1000);$("div.OnlinePoll ul.Graph").slideDown(1000);vote.fadeIn(2000);if($("#survey_divThankYou").length){$("#survey_divThankYou").hide();$("#survey_divQuestion").fadeIn(2000);}
return false;});vote.bind('click',function(){var graph=$("div.OnlinePoll ul.Graph:hidden");var chose=$("div.OnlinePoll input:radio:checked");if(!graph.length){$(this).hide();$("div.OnlinePoll ul.Graph").slideUp(1000);$("div.OnlinePoll fieldset.Choices").slideDown(2000);viewresult.fadeIn(1000);$(this).fadeIn(500);return false;};if(chose.length)return true;return false;});if(!vote.length&&!viewresult.length){$("div.OnlinePoll ul.Graph").show();}}
function executeHandlers(){ip$.assignFirstAndLastChild();invoicesHandler();hideFlashNav();LoginHandler();SearchBoxHandler("site search for");SearchBoxHandlerArabic("إبحث في الموقع");tabHandler();MustSeeTvHandler();fixSelectBug();OfferRotator();faqHandler();inputFilterHandler();SubscribeHandler();ShowGuideHandler();AtoZlist();RenewContract();STSHandler();FixFirefoxMac();TrailerHandler();OnlinePoll();if($("ul#Ticker01").length){if(currentPageLocale=="ar_ae")$("ul#Ticker01").liScroll2({travelocity:0.04});else $("ul#Ticker01").liScroll({travelocity:0.04});}}
jQuery.fn.liScroll=function(settings){settings=jQuery.extend({travelocity:0.07},settings);return this.each(function(){var $strip=jQuery(this);$strip.addClass("newsticker")
var stripWidth=0;var $mask=$strip.wrap("<div class='mask'></div>");var $tickercontainer=$strip.parent().wrap("<div class='tickercontainer'></div>");var containerWidth=$strip.parent().parent().width();$strip.find("li").each(function(i){stripWidth+=jQuery(this,i).width();});$strip.width(stripWidth);var defTiming=stripWidth/settings.travelocity;var totalTravel=stripWidth+containerWidth;function scrollnews(spazio,tempo){$strip.animate({left:'-='+spazio},tempo,"linear",function(){$strip.css("left",containerWidth);scrollnews(totalTravel,defTiming);});}
scrollnews(totalTravel,defTiming);$strip.hover(function(){jQuery(this).stop();},function(){var offset=jQuery(this).offset();var residualSpace=offset.left+stripWidth;var residualTime=residualSpace/settings.travelocity;scrollnews(residualSpace,residualTime);});});};jQuery.fn.liScroll2=function(settings){settings=jQuery.extend({travelocity:0.07},settings);return this.each(function(){var $strip=jQuery(this);$strip.addClass("newsticker")
var stripWidth=0;var $mask=$strip.wrap("<div class='mask'></div>");var $tickercontainer=$strip.parent().wrap("<div class='tickercontainer'></div>");var containerWidth=$strip.parent().parent().width();$strip.find("li").each(function(i){stripWidth+=jQuery(this,i).width();});$strip.width(stripWidth);var defTiming=stripWidth/settings.travelocity;var totalTravel=stripWidth+containerWidth;function scrollnews(spazio,tempo){$strip.animate({right:'-='+spazio},tempo,"linear",function(){$strip.css("right",containerWidth);scrollnews(totalTravel,defTiming);});}
scrollnews(totalTravel,defTiming);$strip.hover(function(){jQuery(this).stop();},function(){var offset=jQuery(this).offset();var residualSpace=offset.left+stripWidth;var residualTime=residualSpace/settings.travelocity;scrollnews(residualSpace,residualTime);});});};function popup(URL,Width,Height,Scrollable,Resizable){Popup(URL,Width,Height,Scrollable,Resizable);}
function Popup(URL,Width,Height,Scrollable,Resizable)
{try
{var Popup;Popup=window.open(URL,"Popup","width = "+Width+", height = "+Height+", top = "+((screen.height-Height)/2)+", left = "+((screen.width-Width)/2)+", resizable = "+(Resizable?"yes":"no")+", scrollbars = "+(Scrollable?"yes":"no")+", status = no");if(parseInt(navigator.appVersion)>=4)
{Popup.window.focus();}}
catch(ExceptionObject)
{alert("Your browser or a piece of software installed on your\ncomputer appears to be blocking popups on this page.\n\nPlease enable popups and refresh this page to continue.");}
return false;}
function OnKeypressNumericfilter(event,Reference)
{var keycode;if(event.keyCode)keycode=event.keyCode;else if(event.which)keycode=event.which;if((keycode>47)&&(keycode<59)||(keycode==32))
{return(true);}
else
{return(false);}}
function RegisterAutoResizeIFrame(IFrameTagId)
{try
{var b=new Proximity.Browser();if(b.isIE()||b.isModern())
{IFrameTag=ip$.getID(IFrameTagId);IFrameTag.style.display="block";if(IFrameTag.addEventListener)
{IFrameTag.addEventListener("load",AutoResizeIFrame,false);}
else if(IFrameTag.attachEvent)
{IFrameTag.attachEvent("onload",AutoResizeIFrame);}
else
{IFrameTag.onload=AutoResizeIFrame;}}}
catch(ExceptionObject)
{}}
function AutoResizeIFrame()
{try
{if(typeof(IFrameTag)!="undefined")
{IFrameTag.height=IFrameTag.contentWindow.document.body.scrollHeight;IFrameTag.style.overflow="hidden";}}
catch(ExceptionObject)
{}}
function OnSelectChangeValue(ExecutingPageLocale)
{try
{var SelectedAnswer
for(i=0;i<document.__aspnetForm.Choices.length;i++){if(document.__aspnetForm.Choices[i].checked==true){SelectedAnswer=document.__aspnetForm.Choices[i].value
break}}
var IdAndAnswer=SelectedAnswer.split(":");var SurveyAnswerId="";var SurveyAnswer="";if(IdAndAnswer.length>0)
{SurveyAnswerId=IdAndAnswer[0];SurveyAnswer=IdAndAnswer[1];}
hdnQuestion=document.getElementById("hdnSurveyQuestion");var PopupURL='/Competition/default_'+ExecutingPageLocale+'.aspx?Question='+hdnQuestion.value.replace("?",'')+'&AnswerId='+SurveyAnswerId+'&Answer='+SurveyAnswer;Popup(PopupURL,516,500,1,0);}
catch(ExceptionObject)
{}}
function OneStat_Pageview()
{var d=document;var sid="199385";var CONTENTSECTION="";var CUSTOMDATA="";var osp_URL=d.URL;var osp_Title=d.title;var t=new Date();var p="http"+(document.URL.indexOf('https:')==0?'s':'')+"://stat.onestat.com/stat.aspx?tagver=2&sid="+sid;p+="&url="+escape(osp_URL);p+="&ti="+escape(osp_Title);p+="&section="+escape(CONTENTSECTION);p+="&custom="+escape(CUSTOMDATA);p+="&rf="+escape(parent==self?window.document.referrer:top.document.referrer);p+="&tz="+escape(t.getTimezoneOffset());p+="&ch="+escape(t.getHours());p+="&js=1";p+="&ul="+escape(navigator.appName=="Netscape"?navigator.language:navigator.userLanguage);if(typeof(screen)=="object"){p+="&sr="+screen.width+"x"+screen.height;p+="&cd="+screen.colorDepth;p+="&jo="+(navigator.javaEnabled()?"Yes":"No");}
d.write('<A HREF="http://www.onestat.com/aspx/login.aspx?sid='+sid+'" target=_blank><IMG ID="ONESTAT_TAG" BORDER="0" WIDTH="1" HEIGHT="1" SRC="'+p+'" ></A>');}
function GetPosOffset(what,OffsetType)
{try
{var totaloffset=(OffsetType=="left")?what.offsetLeft:what.offsetTop;var ParentEl=what.offsetParent;while(ParentEl!=null)
{totaloffset=(OffsetType=="left")?totaloffset+ParentEl.offsetLeft:totaloffset+ParentEl.offsetTop;ParentEl=ParentEl.offsetParent;}
return totaloffset;}
catch(ExceptionObject)
{}}
function ToggleCalendar(LinkObject,InputControlId)
{try
{var Calender=document.getElementById("Calendar");Calender.onmouseout=new Function("this.style.display='none';");Calender.onmouseover=function(){this.style.display='block';window.clearTimeout(killTimeout);};Calender.style.display="block";Calender.onclick=new Function("this.style.display='none';");return false;}
catch(ExceptionObject)
{}}
var UFO={req:["movie","width","height","majorversion","build"],opt:["play","loop","menu","quality","scale","salign","wmode","bgcolor","base","flashvars","devicefont","allowscriptaccess","seamlesstabbing"],optAtt:["id","name","align"],optExc:["swliveconnect"],ximovie:"ufo.swf",xiwidth:"215",xiheight:"138",ua:navigator.userAgent.toLowerCase(),pluginType:"",fv:[0,0],foList:[],create:function(FO,id){if(!UFO.uaHas("w3cdom")||UFO.uaHas("ieMac"))return
UFO.getFlashVersion()
UFO.foList[id]=UFO.updateFO(FO)
UFO.createCSS("#"+id,"visibility:hidden;")
UFO.domLoad(id)},updateFO:function(FO){if(typeof FO.xi!="undefined"&&FO.xi=="true"){if(typeof FO.ximovie=="undefined")FO.ximovie=UFO.ximovie
if(typeof FO.xiwidth=="undefined")FO.xiwidth=UFO.xiwidth
if(typeof FO.xiheight=="undefined")FO.xiheight=UFO.xiheight}
FO.mainCalled=false
return FO},domLoad:function(id){var _t=setInterval(function(){if((document.getElementsByTagName("body")[0]!=null||document.body!=null)&&document.getElementById(id)!=null){UFO.main(id)
clearInterval(_t)}},250)
if(typeof document.addEventListener!="undefined"){document.addEventListener("DOMContentLoaded",function(){UFO.main(id);clearInterval(_t);},null)}},main:function(id){var _fo=UFO.foList[id]
if(_fo.mainCalled)return
UFO.foList[id].mainCalled=true
document.getElementById(id).style.visibility="hidden"
if(UFO.hasRequired(id)){if(UFO.hasFlashVersion(parseInt(_fo.majorversion,10),parseInt(_fo.build,10))){if(typeof _fo.setcontainercss!="undefined"&&_fo.setcontainercss=="true")UFO.setContainerCSS(id)
UFO.writeSWF(id)}
else if(_fo.xi=="true"&&UFO.hasFlashVersion(6,65)){UFO.createDialog(id)}}
document.getElementById(id).style.visibility="visible"},createCSS:function(selector,declaration){var _h=document.getElementsByTagName("head")[0]
var _s=UFO.createElement("style")
if(!UFO.uaHas("ieWin"))_s.appendChild(document.createTextNode(selector+" {"+declaration+"}"))
_s.setAttribute("type","text/css")
_s.setAttribute("media","screen")
_h.appendChild(_s)
if(UFO.uaHas("ieWin")&&document.styleSheets&&document.styleSheets.length>0){var _ls=document.styleSheets[document.styleSheets.length-1]
if(typeof _ls.addRule=="object")_ls.addRule(selector,declaration)}},setContainerCSS:function(id){var _fo=UFO.foList[id]
var _w=/%/.test(_fo.width)?"":"px"
var _h=/%/.test(_fo.height)?"":"px"
UFO.createCSS("#"+id,"width:"+_fo.width+_w+"; height:"+_fo.height+_h+";")
if(_fo.width=="100%"){UFO.createCSS("body","margin-left:0; margin-right:0; padding-left:0; padding-right:0;")}
if(_fo.height=="100%"){UFO.createCSS("html","height:100%; overflow:hidden;")
UFO.createCSS("body","margin-top:0; margin-bottom:0; padding-top:0; padding-bottom:0; height:100%;")}},createElement:function(el){return(UFO.uaHas("xml")&&typeof document.createElementNS!="undefined")?document.createElementNS("http://www.w3.org/1999/xhtml",el):document.createElement(el)},createObjParam:function(el,aName,aValue){var _p=UFO.createElement("param")
_p.setAttribute("name",aName)
_p.setAttribute("value",aValue)
el.appendChild(_p)},uaHas:function(ft){var _u=UFO.ua
switch(ft){case"w3cdom":return(typeof document.getElementById!="undefined"&&typeof document.getElementsByTagName!="undefined"&&(typeof document.createElement!="undefined"||typeof document.createElementNS!="undefined"))
case"xml":var _m=document.getElementsByTagName("meta")
var _l=_m.length
for(var i=0;i<_l;i++){if(/content-type/i.test(_m[i].getAttribute("http-equiv"))&&/xml/i.test(_m[i].getAttribute("content")))return true}
return false
case"ieMac":return/msie/.test(_u)&&!/opera/.test(_u)&&/mac/.test(_u)
case"ieWin":return/msie/.test(_u)&&!/opera/.test(_u)&&/win/.test(_u)
case"gecko":return/gecko/.test(_u)&&!/applewebkit/.test(_u)
case"opera":return/opera/.test(_u)
case"safari":return/applewebkit/.test(_u)
default:return false}},getFlashVersion:function(){if(UFO.fv[0]!=0)return
if(navigator.plugins&&typeof navigator.plugins["Shockwave Flash"]=="object"){UFO.pluginType="npapi"
var _d=navigator.plugins["Shockwave Flash"].description
if(typeof _d!="undefined"){_d=_d.replace(/^.*\s+(\S+\s+\S+$)/,"$1")
var _m=parseInt(_d.replace(/^(.*)\..*$/,"$1"),10)
var _r=/r/.test(_d)?parseInt(_d.replace(/^.*r(.*)$/,"$1"),10):0
UFO.fv=[_m,_r]}}
else if(window.ActiveXObject){UFO.pluginType="ax"
try{var _a=new ActiveXObject("ShockwaveFlash.ShockwaveFlash.7")}
catch(e){try{var _a=new ActiveXObject("ShockwaveFlash.ShockwaveFlash.6")
UFO.fv=[6,0]
_a.AllowScriptAccess="always"}
catch(e){if(UFO.fv[0]==6)return}
try{var _a=new ActiveXObject("ShockwaveFlash.ShockwaveFlash")}
catch(e){}}
if(typeof _a=="object"){var _d=_a.GetVariable("$version")
if(typeof _d!="undefined"){_d=_d.replace(/^\S+\s+(.*)$/,"$1").split(",")
UFO.fv=[parseInt(_d[0],10),parseInt(_d[2],10)]}}}},hasRequired:function(id){var _l=UFO.req.length
for(var i=0;i<_l;i++){if(typeof UFO.foList[id][UFO.req[i]]=="undefined")return false}
return true},hasFlashVersion:function(major,release){return(UFO.fv[0]>major||(UFO.fv[0]==major&&UFO.fv[1]>=release))?true:false},writeSWF:function(id){var _fo=UFO.foList[id]
var _e=document.getElementById(id)
if(UFO.pluginType=="npapi"){if(UFO.uaHas("gecko")||UFO.uaHas("xml")){while(_e.hasChildNodes()){_e.removeChild(_e.firstChild)}
var _obj=UFO.createElement("object")
_obj.setAttribute("type","application/x-shockwave-flash")
_obj.setAttribute("data",_fo.movie)
_obj.setAttribute("width",_fo.width)
_obj.setAttribute("height",_fo.height)
var _l=UFO.optAtt.length
for(var i=0;i<_l;i++){if(typeof _fo[UFO.optAtt[i]]!="undefined")_obj.setAttribute(UFO.optAtt[i],_fo[UFO.optAtt[i]])}
var _o=UFO.opt.concat(UFO.optExc)
var _l=_o.length
for(var i=0;i<_l;i++){if(typeof _fo[_o[i]]!="undefined")UFO.createObjParam(_obj,_o[i],_fo[_o[i]])}
_e.appendChild(_obj)}
else{var _emb=""
var _o=UFO.opt.concat(UFO.optAtt).concat(UFO.optExc)
var _l=_o.length
for(var i=0;i<_l;i++){if(typeof _fo[_o[i]]!="undefined")_emb+=' '+_o[i]+'="'+_fo[_o[i]]+'"'}
_e.innerHTML='<embed type="application/x-shockwave-flash" src="'+_fo.movie+'" width="'+_fo.width+'" height="'+_fo.height+'" pluginspage="http://www.macromedia.com/go/getflashplayer"'+_emb+'></embed>'}}
else if(UFO.pluginType=="ax"){var _objAtt=""
var _l=UFO.optAtt.length
for(var i=0;i<_l;i++){if(typeof _fo[UFO.optAtt[i]]!="undefined")_objAtt+=' '+UFO.optAtt[i]+'="'+_fo[UFO.optAtt[i]]+'"'}
var _objPar=""
var _l=UFO.opt.length
for(var i=0;i<_l;i++){if(typeof _fo[UFO.opt[i]]!="undefined")_objPar+='<param name="'+UFO.opt[i]+'" value="'+_fo[UFO.opt[i]]+'" />'}
var _p=window.location.protocol=="https:"?"https:":"http:"
_e.innerHTML='<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000"'+_objAtt+' width="'+_fo.width+'" height="'+_fo.height+'" codebase="'+_p+'//download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version='+_fo.majorversion+',0,'+_fo.build+',0"><param name="movie" value="'+_fo.movie+'" />'+_objPar+'</object>';}},createDialog:function(id){var _fo=UFO.foList[id]
UFO.createCSS("html","height:100%; overflow:hidden;")
UFO.createCSS("body","height:100%; overflow:hidden;")
UFO.createCSS("#xi-con","position:absolute; left:0; top:0; z-index:1000; width:100%; height:100%; background-color:#fff; filter:alpha(opacity:75); opacity:0.75;")
UFO.createCSS("#xi-dia","position:absolute; left:50%; top:50%; margin-left: -"+Math.round(parseInt(_fo.xiwidth,10)/2)+"px; margin-top: -"+Math.round(parseInt(_fo.xiheight,10)/2)+"px; width:"+_fo.xiwidth+"px; height:"+_fo.xiheight+"px;")
var _b=document.getElementsByTagName("body")[0]
var _c=UFO.createElement("div")
_c.setAttribute("id","xi-con")
var _d=UFO.createElement("div")
_d.setAttribute("id","xi-dia")
_c.appendChild(_d)
_b.appendChild(_c)
var _mmu=window.location
if(UFO.uaHas("xml")&&UFO.uaHas("safari")){var _mmd=document.getElementsByTagName("title")[0].firstChild.nodeValue=document.getElementsByTagName("title")[0].firstChild.nodeValue.slice(0,47)+" - Flash Player Installation"}
else{var _mmd=document.title=document.title.slice(0,47)+" - Flash Player Installation"}
var _mmp=UFO.pluginType=="ax"?"ActiveX":"PlugIn"
var _uc=typeof _fo.xiurlcancel!="undefined"?"&xiUrlCancel="+_fo.xiurlcancel:""
var _uf=typeof _fo.xiurlfailed!="undefined"?"&xiUrlFailed="+_fo.xiurlfailed:""
UFO.foList["xi-dia"]={movie:_fo.ximovie,width:_fo.xiwidth,height:_fo.xiheight,majorversion:"6",build:"65",flashvars:"MMredirectURL="+_mmu+"&MMplayerType="+_mmp+"&MMdoctitle="+_mmd+_uc+_uf}
UFO.writeSWF("xi-dia")},expressInstallCallback:function(){var _b=document.getElementsByTagName("body")[0]
var _c=document.getElementById("xi-con")
_b.removeChild(_c)
UFO.createCSS("body","height:auto; overflow:auto;")
UFO.createCSS("html","height:auto; overflow:auto;")},cleanupIELeaks:function(){var _o=document.getElementsByTagName("object")
var _l=_o.length
for(var i=0;i<_l;i++){_o[i].style.display="none"
for(var x in _o[i]){if(typeof _o[i][x]=="function"){_o[i][x]=null}}}}}
if(typeof window.attachEvent!="undefined"&&UFO.uaHas("ieWin")){window.attachEvent("onunload",UFO.cleanupIELeaks)}
function SetGlobalBrowserVariables()
{try
{if(typeof(GlobalBrowserVariablesSet)=="undefined")
{GlobalBrowserVariablesSet=true;Opera=!!(window.opera&&document.getElementById);Opera6=Opera&&!document.defaultView;Opera7=Opera&&!Opera6;InternetExplorer=navigator.userAgent.toLowerCase().indexOf("msie")!=-1&&document.all&&((document.compatMode&&document.compatMode!="BackCompat")?document.documentElement:document.body?document.body:null)&&!Opera;InternetExplorer6=InternetExplorer&&parseFloat(navigator.appVersion.substring(navigator.appVersion.indexOf("MSIE")+5))>=5.5;NetscapeNavigator4=(document.layers&&typeof document.classes!="undefined");NetscapeNavigator6=(!Opera&&document.defaultView&&typeof document.defaultView.getComputedStyle!="undefined");W3CCompliant=!InternetExplorer&&!NetscapeNavigator6&&!Opera&&document.getElementById;DocumentBody=(((document.compatMode)&&(document.compatMode!="BackCompat"))?document.documentElement:((document.body)?document.body:null));PixelSuffix=(Opera6||NetscapeNavigator4)?"":"px";}}
catch(ExceptionObject)
{}}
function InitializeToolTip()
{try
{SetGlobalBrowserVariables();var MenuRootNodeGroupTag=document.getElementById("ChannelBox");var MenuNodeTag=MenuRootNodeGroupTag.getElementsByTagName("LI");for(var i=0;i<MenuNodeTag.length;i++)
{var MenuChildNodeGroupTag=MenuNodeTag[i].getElementsByTagName("DIV");if(MenuChildNodeGroupTag.length>0)
{MenuNodeTag[i].onmouseover=new Function("ShowToolTip(this);");MenuNodeTag[i].onmouseout=new Function("HideToolTip(this);")}}}
catch(ExceptionObject)
{}}
function ShowToolTip(MenuNodeTag)
{try
{var MenuChildNodeGroupTag=MenuNodeTag.getElementsByTagName("DIV");var TopMargin;var ChannelBox;if(MenuChildNodeGroupTag.length>0)
{MenuChildNodeGroupTag[0].style.display="block";TopMargin=-(MenuChildNodeGroupTag[0].offsetHeight+40);MenuChildNodeGroupTag[0].style.marginTop=TopMargin+"px";}}
catch(ExceptionObject)
{}}
function HideToolTip(MenuNodeTag)
{var MenuChildNodeGroupTag=MenuNodeTag.getElementsByTagName("DIV");if(MenuChildNodeGroupTag.length>0)
{MenuChildNodeGroupTag[0].style.display="none";}}
if (typeof deconcept == "undefined") { var deconcept = new Object(); } if (typeof deconcept.util == "undefined") { deconcept.util = new Object(); } if (typeof deconcept.SWFObjectUtil == "undefined") { deconcept.SWFObjectUtil = new Object(); } deconcept.SWFObject = function (_1, id, w, h, _5, c, _7, _8, _9, _a) { if (!document.getElementById) { return; } this.DETECT_KEY = _a ? _a : "detectflash"; this.skipDetect = deconcept.util.getRequestParameter(this.DETECT_KEY); this.params = new Object(); this.variables = new Object(); this.attributes = new Array(); if (_1) { this.setAttribute("swf", _1); } if (id) { this.setAttribute("id", id); } if (w) { this.setAttribute("width", w); } if (h) { this.setAttribute("height", h); } if (_5) { this.setAttribute("version", new deconcept.PlayerVersion(_5.toString().split("."))); } this.installedVer = deconcept.SWFObjectUtil.getPlayerVersion(); if (!window.opera && document.all && this.installedVer.major > 7) { deconcept.SWFObject.doPrepUnload = true; } if (c) { this.addParam("bgcolor", c); } var q = _7 ? _7 : "high"; this.addParam("quality", q); this.setAttribute("useExpressInstall", false); this.setAttribute("doExpressInstall", false); var _c = (_8) ? _8 : window.location; this.setAttribute("xiRedirectUrl", _c); this.setAttribute("redirectUrl", ""); if (_9) { this.setAttribute("redirectUrl", _9); } }; deconcept.SWFObject.prototype = { useExpressInstall: function (_d) { this.xiSWFPath = !_d ? "expressinstall.swf" : _d; this.setAttribute("useExpressInstall", true); }, setAttribute: function (_e, _f) { this.attributes[_e] = _f; }, getAttribute: function (_10) { return this.attributes[_10]; }, addParam: function (_11, _12) { this.params[_11] = _12; }, getParams: function () { return this.params; }, addVariable: function (_13, _14) { this.variables[_13] = _14; }, getVariable: function (_15) { return this.variables[_15]; }, getVariables: function () { return this.variables; }, getVariablePairs: function () { var _16 = new Array(); var key; var _18 = this.getVariables(); for (key in _18) { _16[_16.length] = key + "=" + _18[key]; } return _16; }, getSWFHTML: function () { var _19 = ""; if (navigator.plugins && navigator.mimeTypes && navigator.mimeTypes.length) { if (this.getAttribute("doExpressInstall")) { this.addVariable("MMplayerType", "PlugIn"); this.setAttribute("swf", this.xiSWFPath); } _19 = "<embed type=\"application/x-shockwave-flash\" src=\"" + this.getAttribute("swf") + "\" width=\"" + this.getAttribute("width") + "\" height=\"" + this.getAttribute("height") + "\" style=\"" + this.getAttribute("style") + "\""; _19 += " id=\"" + this.getAttribute("id") + "\" name=\"" + this.getAttribute("id") + "\" "; var _1a = this.getParams(); for (var key in _1a) { _19 += [key] + "=\"" + _1a[key] + "\" "; } var _1c = this.getVariablePairs().join("&"); if (_1c.length > 0) { _19 += "flashvars=\"" + _1c + "\""; } _19 += "/>"; } else { if (this.getAttribute("doExpressInstall")) { this.addVariable("MMplayerType", "ActiveX"); this.setAttribute("swf", this.xiSWFPath); } _19 = "<object id=\"" + this.getAttribute("id") + "\" classid=\"clsid:D27CDB6E-AE6D-11cf-96B8-444553540000\" width=\"" + this.getAttribute("width") + "\" height=\"" + this.getAttribute("height") + "\" style=\"" + this.getAttribute("style") + "\">"; _19 += "<param name=\"movie\" value=\"" + this.getAttribute("swf") + "\" />"; var _1d = this.getParams(); for (var key in _1d) { _19 += "<param name=\"" + key + "\" value=\"" + _1d[key] + "\" />"; } var _1f = this.getVariablePairs().join("&"); if (_1f.length > 0) { _19 += "<param name=\"flashvars\" value=\"" + _1f + "\" />"; } _19 += "</object>"; } return _19; }, write: function (_20) { if (this.getAttribute("useExpressInstall")) { var _21 = new deconcept.PlayerVersion([6, 0, 65]); if (this.installedVer.versionIsValid(_21) && !this.installedVer.versionIsValid(this.getAttribute("version"))) { this.setAttribute("doExpressInstall", true); this.addVariable("MMredirectURL", escape(this.getAttribute("xiRedirectUrl"))); document.title = document.title.slice(0, 47) + " - Flash Player Installation"; this.addVariable("MMdoctitle", document.title); } } if (this.skipDetect || this.getAttribute("doExpressInstall") || this.installedVer.versionIsValid(this.getAttribute("version"))) { var n = (typeof _20 == "string") ? document.getElementById(_20) : _20; n.innerHTML = this.getSWFHTML(); return true; } else { if (this.getAttribute("redirectUrl") != "") { document.location.replace(this.getAttribute("redirectUrl")); } } return false; } }; deconcept.SWFObjectUtil.getPlayerVersion = function () { var _23 = new deconcept.PlayerVersion([0, 0, 0]); if (navigator.plugins && navigator.mimeTypes.length) { var x = navigator.plugins["Shockwave Flash"]; if (x && x.description) { _23 = new deconcept.PlayerVersion(x.description.replace(/([a-zA-Z]|\s)+/, "").replace(/(\s+r|\s+b[0-9]+)/, ".").split(".")); } } else { if (navigator.userAgent && navigator.userAgent.indexOf("Windows CE") >= 0) { var axo = 1; var _26 = 3; while (axo) { try { _26++; axo = new ActiveXObject("ShockwaveFlash.ShockwaveFlash." + _26); _23 = new deconcept.PlayerVersion([_26, 0, 0]); } catch (e) { axo = null; } } } else { try { var axo = new ActiveXObject("ShockwaveFlash.ShockwaveFlash.7"); } catch (e) { try { var axo = new ActiveXObject("ShockwaveFlash.ShockwaveFlash.6"); _23 = new deconcept.PlayerVersion([6, 0, 21]); axo.AllowScriptAccess = "always"; } catch (e) { if (_23.major == 6) { return _23; } } try { axo = new ActiveXObject("ShockwaveFlash.ShockwaveFlash"); } catch (e) { } } if (axo != null) { _23 = new deconcept.PlayerVersion(axo.GetVariable("$version").split(" ")[1].split(",")); } } } return _23; }; deconcept.PlayerVersion = function (_29) { this.major = _29[0] != null ? parseInt(_29[0]) : 0; this.minor = _29[1] != null ? parseInt(_29[1]) : 0; this.rev = _29[2] != null ? parseInt(_29[2]) : 0; }; deconcept.PlayerVersion.prototype.versionIsValid = function (fv) { if (this.major < fv.major) { return false; } if (this.major > fv.major) { return true; } if (this.minor < fv.minor) { return false; } if (this.minor > fv.minor) { return true; } if (this.rev < fv.rev) { return false; } return true; }; deconcept.util = { getRequestParameter: function (_2b) { var q = document.location.search || document.location.hash; if (_2b == null) { return q; } if (q) { var _2d = q.substring(1).split("&"); for (var i = 0; i < _2d.length; i++) { if (_2d[i].substring(0, _2d[i].indexOf("=")) == _2b) { return _2d[i].substring((_2d[i].indexOf("=") + 1)); } } } return ""; } }; deconcept.SWFObjectUtil.cleanupSWFs = function () { var _2f = document.getElementsByTagName("OBJECT"); for (var i = _2f.length - 1; i >= 0; i--) { _2f[i].style.display = "none"; for (var x in _2f[i]) { if (typeof _2f[i][x] == "function") { _2f[i][x] = function () { }; } } } }; if (deconcept.SWFObject.doPrepUnload) { if (!deconcept.unloadSet) { deconcept.SWFObjectUtil.prepUnload = function () { __flash_unloadHandler = function () { }; __flash_savedUnloadHandler = function () { }; window.attachEvent("onunload", deconcept.SWFObjectUtil.cleanupSWFs); }; window.attachEvent("onbeforeunload", deconcept.SWFObjectUtil.prepUnload); deconcept.unloadSet = true; } } if (!document.getElementById && document.all) { document.getElementById = function (id) { return document.all[id]; }; } var getQueryParamValue = deconcept.util.getRequestParameter; var FlashObject = deconcept.SWFObject; var SWFObject = deconcept.SWFObject;

function JQPopup(URL, Width, Height, Scrollable, Resizable) {
    //alert(URL);
    try {
        window.top.$('#frmPopUp').attr('src', URL);
        window.top.$('#divPopUp').fadeIn();
    }
    catch (e)
    { }
}
function CloseJQPopUp() {
    try {
        window.top.$('#frmPopUp').attr('src', '');
        $('#divPopUp').fadeOut();
        $('#divLogin').fadeOut();
    }
    catch (e)
{ }
}
function JQLPopup(URL, Width, Height, Scrollable, Resizable) {
    try {
        //alert('LoginFrame');
        window.top.$('#LoginFrame').attr('src', URL);
        window.top.$('#divLogin').fadeIn();
    }
    catch (e)
    { }
}
function CloseJQLPopUp() {
    try {
        $('#divLogin').fadeOut();
    }
    catch (e)
{ }
}
