<!--
///******************************///
///***                        ***///
///***   www.GB-SOFT.cz 2006  ***///
///***                        ***///
///******************************///
var ip = '<!--#echo var="REMOTE_ADDR"-->';

var s = " " ;
var error_count=0;
var lastli=3;
function GetCookie(name,vall) 
{
try
{
	var result = vall;
	var myCookie = " " + document.cookie + ";";
	var searchName = " " + name + "=";
	var startOfCookie = myCookie.indexOf(searchName);
	var endOfCookie;
	if (startOfCookie != -1) 
	{
		startOfCookie += searchName.length; 
		endOfCookie = myCookie.indexOf(";", startOfCookie);
		result = unescape(myCookie.substring(startOfCookie, endOfCookie));
	}
	//alert(result);
	return result;
	
}catch(e)
{
//alert('chyba cokies');
};
}

function SetCookie(name, value) 
{
//alert(value);
try
{	if (name)
	{	
		var never = new Date();

		if (value)
		{
			never.setDate (1); 
			never.setMonth (1); 
			never.setYear (2037);
		}
		else 
			never.setTime(never.getTime() - 1);

		var expString = "; expires=" + never.toGMTString();
        //var expString = "; expires=Fri, 02-Jan-2100 00:00:00" ;
		document.cookie = name + "=" + value + expString + "; path=/";
	}
 	//alert(name + "=" + value + expString + "; path=/")
 	//alert(document.cookie);
}catch(e)
{
alert('chyba cokies');
}

}

function IsCookieEnabled() 
{
	SetCookie("testKey", "1");

	if (GetCookie("testKey") == "1")
		return 1;

	return 0;
}
//alert('aha 2');

var er=0;
try
{
if(er==0)dle_hodiny.innerHTML='JavaScript Init moment' ;
}
catch(e)
{
er=1;
//alert(e.message);
};

if(er==0)
{
 if (document.all) {
  var arg1=udalosti.length;
  var arg2=999;
  //alert(0)
}else{
  var arg1=null;
  //var x=document.getElementById('udalosti')
  var arg2="udalosti.options[0]";
  //alert(1)
}
}

var no = new Option();no.value   =08;no.text = '07';hist .add(no,arg1);
var no = new Option();no.value   =15;no.text = '14';hist .add(no,1);
var no = new Option();no.value   =32;no.text = '31';hist .add(no,2);
var no = new Option();no.value   =63;no.selected='62';no.text = '62';hist .add(no,3);
var no = new Option();no.value   =91;no.text = '90';hist .add(no,4);
var no = new Option();no.value   =121;no.text = '120';hist .add(no,5);
var no = new Option();no.value   =160;no.text = '160';hist .add(no,6);
C1.checked=GetCookie ( 'C1', C1.checked ) ;
C2.checked=GetCookie ( 'C2' , C2.checked ) ;
C3.checked=GetCookie ( 'C3' , C3.checked ) ;
//C4.checked=true;//GetCookie ( 'C4' , C4.checked ) ;
C5.checked=GetCookie ( 'C5' , C5.checked ) ;
CT2.checked=GetCookie( 'CT2', CT2.checked ) ;
//CT4.checked=GetCookie( 'CT4', CT4.checked ) ;
hist.selectedIndex = GetCookie ( 'hist', 3 )- 1 ;
hhi=hist.options[hist.selectedIndex].value;

////////////////////////////////////////////////////////
//status prehravani

var h='';
var hlaska='';
var state=0;
var ers='';
function sp()
{
//if(prog.innerHTML!='Status:' +video0.status+' br:'+video0.network.bitRate)
//{   prog.innerHTML='Status:' +video0.status+' br:'+video0.network.bitRate;
//if(er==1)alert('test');
if(er==0)
{
 if(error_count>=1){ers='('+error_count+')'}else{ers='.'}
 h=video0.status+ers+htt;
 //alert('"'+h+'"'+'+'+'"'+prg.innerHTML+'"');
 if(prg.innerHTML!=h)
 {   
   prg.innerHTML=h;
 }
 if(h!='undefined'+ers+htt){
   if((state==6)||(0==h.indexOf('Connecting'))){window.setTimeout("sp()",1000);}else{window.setTimeout("sp()",10000);}
 }
 else
 {
 if(prg.innerHTML!=''){prg.innerHTML='...';C2.checked=true;}
 }
}
else
{co.value=h+hlaska;}
}
 
sp();

///////////////////////////////////////////////////////////

//alert('aha5');
if(er==1){co.value='<<-- JavaScript Init moment -->>';}
else{co2.innerHTML='<<-- JavaScript Init moment -->>';}


var mili = 1000*60*60*24;
function addDay(_a,_b){_a.setTime(_a.getTime()+_b*mili);}

var xxx = 154 ;
var yyy =  32 ;
var plus = 60 ;
var start = 0 ;

var oh=0;rw=0; tw=0; th=0; kch=0;
if (chrome!=-1){kch=10}else{kch=32}
try
{
video0.width=document.body.offsetWidt-35 
video0.height=390 
}catch(e){};

function resize()
{ 
try
{
 if(!mobile)
 if (wc==-1)
 {
  try{if(window.innerHeight){oh=window.innerHeight;}else{oh=document.body.offsetHeight}}
  catch(e){oh=document.body.offsetHeight};  
//if (oh>=800){oh=800}
try{if(!mobile)if(oh>=(screen.height-200)){oh=screen.height-200;}}catch(e){};
  if (document.body.offsetWidth<=640){kor=0;kor2=0;}
  if(((document.body.offsetWidth-yyy)*ind)>=(oh-xxx-12))
  {
  tw=(oh-xxx)*(ind2);
  th=oh-xxx+64;
  video0.width=tw-kor;
  video0.height=th-kor2;
  }
  else
  {
//  tw=  (document.body.offsetWidth-32);
  tw= (document.body.offsetWidth-kch);
  th=((document.body.offsetWidth   )*ind)+41;
  video0.width=  tw-kor;
  video0.height= th-kor2;
  //alert(video0.height);
  }
 }
 else
 {
   //alert(wc)
 }
}catch(e){};

}
resize();
onresize=resize;
//alert('aha6');

var lastx = '' ;
var lastsa = '' ;
var lastpo = '' ;
var last2 = 1 ;
var pd1=new Date();
var pd2=new Date();
var sda1='';
var sda2='';
function skoc(x,sa,po)
{
try
{
 if (po==null) {po=''} ;
 error_count=0;
 //alert(sa)
 if((sa==hct24)||(1<sa.indexOf(hvyb))){skoc2('mms://ct24stream.visual.cz/CT24-',hct24);}
 else
 if(sa==hct1){skoc2(hct1);}
 else
 {
  //co.focus();
  last2=1 ;
  lastx=x;
  lastsa=sa;
  lastpo=po;
 
  var xx='';
  var sss=hlq;
  sda1=x.substr(x.length-2,2)+x.substr(x.length-4,2)+x.substr(x.length-6,2);
  if(true==false)
  {
    //alert(sda1);   
    var ex='.rm.wmv';
    var xxx='mms://stream3.visual.cz/ct/';
    if((0==x .indexOf('Udalostip270106'))){x='Zpravy1200-310106'}
    else
    if((0==x .indexOf('TKO-'))||(0==x .indexOf('TK-'))||(0==x .indexOf('Obj-')))
    {
      if(sda1>='060305')
         x='OVM1-'+x.substr(x.length-6,6) //od 050306 se opet zmenil nazev poradu (';')
      else
         x='TKO-'+x.substr(x.length-6,6)
               
    }
    else
    if(0==x .indexOf('ReporteriCT-'))
    {
      if(sda1>='060327')
         x='UdalostiP'+x.substr(x.length-6,6) //od 050327 se opet zmenil nazev poradu (';')         
    }
    else
    if((0==x .indexOf('Uvolnetese-')))
    {
      if(x.substr(11,6)=='240206')
      x='UdalostiPCT1-'+x.substr(11,6)
      else
      if(x.substr(11,6)=='170206')
      x='UdalostiPCT1-'+x.substr(11,6)
      else
      if((x.substr(11,6)=='200106')||(x.substr(11,6)=='130106')||(x.substr(11,6)=='060106')||(sda1>='060303'))
      x='UdalostiP'+x.substr(11,6)
      else
      if(x.substr(11,6)=='270106')
      x='Zpravy1200-310106';
      
      //alert(x+' '+sda1)
    }
    else
    if (0==po.indexOf('zpravy18')){x='StudioCT24-'+x.substr(11,6);}
    else
    if (po=='AM'){
    if(sda1>='050305'){x='Zpravy1200-'+x.substr(11,6)}
    else {x='Zpravy1200CT1-'+x.substr(11,6)}
    }
    else
    if (x=='UdalostiP270206') {x='UdalostiP-270206'}//je treba doresit zmenu nazvu wmv
    else
    if (x=='Udalosti270206') {x='Udalosti-270206'}//je treba doresit zmenu nazvu wmv
    //else
    //if (x=='UdalostiP280206') {x='UdalostiP-280206'}//je treba doresit zmenu nazvu wmv
    //else
    //if (x=='Udalosti280206') {x='Udalosti-280206'}//je treba doresit zmenu nazvu wmv
  
    
    //alert(x);
    //StudioCT24-110206.rm.wmv
    //alert(xxx+xx+x+ex+' sa:'+sa);
  }
  else
  {
  var xxx='http://ct1streaming.visual.cz/new/asx/';
  var ex='.asx';
  } 
  if (C1.checked==true){xx='high/';sss=hmq}
  //if (1<x .indexOf('/radio/')){}else{ex='';xxx='';xx='';}
  //alert(xxx+xx+x+ex+' sa:'+sa);
  hlaska=hst+sss+' : '+sa;
  if(er==1){co.value=h+hst+sss+' : '+sa;}
  else
  {co2.innerHTML=hst+sss+' : '+sa;bkt=co2.innerHTML;}
  if (C2.checked==true){top.location=xxx+xx+x+ex;video0.controls.stop();video0.close();}
  else
  {video0.URL=xxx+xx+x+ex;
  //window.scrollTo(0, 0);
  //xx.click;
  //im.src='images./bt_play.gif';
  //alert(spus.src);
  video0.autostart=true;
  //alert(xxx+xx+x+ex+'sa:'+sa);
  }
 }
 if (lastli==1)C5.checked=false;
//alert(xxx+xx+x+ex);
 //spf.referer='spusteno:'+hst+sss+' : '+sa;
 //spf.location='spusteno.htm&'+hst+sss+' : '+sa;
}
catch(e)
{}
}
var bkt='';
function skoc2(x,sax,zrus)
{
try
{
if(zrus==null)zrus=false;
last2=2;
lastx=x;
lastsa=sax;
var sss=hlq;
var xxs='Low';
//http://ct1streaming.visual.cz/asx/ct24liveWH.asx
//http://ct1streaming.visual.cz/asx/ct24liveWL.asx

if(x!=hct1){C5.checked=false};
if(x!=hct2){CT2.checked=false};
//if(x!=hct4){CT4.checked=false};
if (C1.checked==true){xxs='High';var sss=hmq;}

if (x==hct1 ){sax=x;xxs='';if (C1.checked==true){x='http://master.nacevi.cz/asx/ct1liveWH.asx'}
                                          else {x='http://master.nacevi.cz/asx/ct1liveWL.asx'}}
if (x==hct2){sax=x;xxs='';if (C1.checked==true){x='http://master.nacevi.cz/asx/ct2liveWH.asx'}
                                           else{x='http://master.nacevi.cz/asx/ct2liveWL.asx'}}
if (x==hct4){sax=x;xxs='';if (C1.checked==true){x='http://master.nacevi.cz/asx/ct4liveWH.asx'}
                                           else{x='http://master.nacevi.cz/asx/ct4liveWL.asx'}}
if(x==hct24){sax=x;xxs='';if (C1.checked==true){x='http://wmtvs.com/asx/live_TV_online_21083.asx'}
                                           else{x='http://wmtvs.com/asx/live_TV_online_21083L.asx'}}
                                           

if (sax==hta3){xxs='';}
if (sax==hmtv){xxs='';}
if (sax==h24cz){xxs='';}

if (x=='mms://62.24.71.90/24.CZ'){xxs='';}
if(x=='http://62.152.235.13/')
{
xxs='';sss='~~';
if((zrus==true)&&(lastli==1))C5.checked=false;
}

if (1<x.indexOf('bcasta.livebox.tv/toptv'))
{
xxs='';
if((zrus==true)&&(lastli==1))C5.checked=false;
//if (C1.checked==false)
//{
//x='mms://bcasta.livebox.tv/toptv?WMBitrate=128000'
//sss='118kbps';}
//else 
//{
//x='mms://bcasta.livebox.tv/toptv?WMBitrate=512000'
//sss='493kbps';
//}
//C4.checked=true
}
  
if(x=='mms://213.211.43.210:49999')
{
xxs='';sss='~~';
if((zrus==true)&&(lastli==1))C5.checked=false;
//x='mms://213.211.43.210' ;
//alert(x);
}
if(x=='http://213.211.43.211/live')
{
xxs='';sss='~~';
if((zrus==true)&&(lastli==1))C5.checked=false;
//x='mms://213.211.43.210' ;
//alert(x);
}
if (true==false)
if (sax==hpg24)
 {
   xxs='';
   if (C1.checked==true){x='mms://82.99.173.138/PG24-High'}
                   else {x='mms://82.99.173.138/PG24-Low'}
  //alert(x)
 }                     
                       
if (sax==h24cz)
 {
   xxs='';
   if (C1.checked==true){x='http://www.24cz-tv.cz/400.asx'}
                   else {x='http://www.24cz-tv.cz/100.asx'}
  //alert(x)
 }                     

//zmena od 23.10.2006 (';')
if (1<x.indexOf('/CT24-'   )){
xxs='';
                     if((zrus==true)&&(lastli==1))C5.checked=false;
//if (C1.checked==true){x='http://ct1streaming.visual.cz/asx/ct24liveWH.asx'}
//                else {x='http://ct1streaming.visual.cz/asx/ct24liveWL.asx'}}
if (C1.checked==true){x='http://www.gb-soft.com/asx/ct24-2.asx'}
                else {x='http://www.gb-soft.com/asx/ct24-1.asx'}}

if (1<x.indexOf('/CT1-'    )){
xxs='';
//if (C1.checked==true){x='http://ct1streaming.visual.cz/asx/ct1liveWH.asx'}
//                else {x='http://ct1streaming.visual.cz/asx/ct1liveWL.asx'}}
if (C1.checked==true){x='http://master.nacevi.cz/asx/ct1liveWH.asx'}
                else {x='http://master.nacevi.cz/asx/ct1liveWL.asx'}}


if (true==true)
{
if (1<x.indexOf('/CT24-'   )){
                     if((zrus==true)&&(lastli==1))C5.checked=false;
//if (C1.checked==true){x='http://ct1streaming.visual.cz/asx/ct24liveWH.asx'}
//                else {x='http://ct1streaming.visual.cz/asx/ct24liveWL.asx'}}
if (C1.checked==true){x='http://www.gb-soft.com/asx/ct24-2.asx'}
                else {x='http://www.gb-soft.com/asx/ct24-1.asx'}}
if (1<x.indexOf('/CT1-'    )){
//if (C1.checked==true){x='http://ct1streaming.visual.cz/asx/ct1liveWH.asx'}
//                else {x='http://ct1streaming.visual.cz/asx/ct1liveWL.asx'}}
if (C1.checked==true){x='http://master.nacevi.cz/asx/ct1liveWH.asx'}
                else {x='http://master.nacevi.cz/asx/ct1liveWL.asx'}}
if (1<x.indexOf('bcasta.livebox.tv/toptv'))
{
if (C1.checked==true){x='http://www.livebox.cz/TOP%2DTV/stream.asx?ID=0&WMBitrate=512000'}
                else {x='http://www.livebox.cz/TOP%2DTV/stream.asx?ID=0&WMBitrate=128000'}  
}
if (x=='mms://62.24.71.90/24.CZ' ){
                      x='http://62.24.71.90/24.CZ.asx';}
if (sax==hpg24)
{
if (C1.checked==true){x='mms://stream.pg24.tv/PG24-High'}
                else {x='mms://stream.pg24.tv/PG24-low'}
                      
}
xxs='';                
}

if (x=='http://stream.idnes.cz/ocko-tv')
{
xxs='';
sss='0.2-8Mbps';
if (C1.checked==true){xxs='-hq';sss='1.3Mbps';}
}

//alert(x+xxs);
hlaska=hst+sss+' : '+sax;
if(er==1)
{co.value=h+hst+sss+' : '+sax;
 bkt=h+hst+sss+' : '+sax;
}
else
{
co2.innerHTML=hst+sss+' : '+sax;
bkt=hst+sss+' : '+sax;
}
//if (1<x .indexOf('/radio/')){}else{ex='';xxs=''}
//alert(x+xxs);
if (C2.checked==true){top.location=x+xxs;video0.controls.stop();video0.close();}
else
{video0.URL=x+xxs;
 //top.location='#prg';
 video0.settings.autoStart=true;
 //window.scrollTo(0, 0);
}
}catch(e)
{
//alert(e.message+' ...')
};
//spus.src='spusteno.htm&'+hlaska;
//alert(spus.src);
}

function skoclast()
{
//alert(lastx+' '+lastsa);
if (lastx!='')
{
if (last2==1){skoc (lastx,lastsa,lastpo)};
if (last2==2){skoc2(lastx,lastsa)};
}
}

var datum='';
var isin=0;
function zpravy_dle_hodiny(jak)
{
if(isin==1){window.setTimeout("zpravy_dle_hodiny('jen dnes');",20000);return};
isin=1;
if(jak==null)jak='nijak';
//alert('a');
var now=new Date();
var now2=new Date();
var yy=now.getYear();
if(yy>=2000){yy=yy-2000;}
if(yy>=100){yy=yy-100;}
var mm=now.getMonth()+1;
var dd=((now.getDate()<10) ?"":"")+now.getDate();
var li=0;
var li2=0;
var li4=0;
var dx=0;
var ss='';
var sx='';
var da='';
if(er==0)
{
var hh=now.getHours();
}
else
{
var hh=now.getHours()+1;
}
if(hh>23){hh=0}
var mi=now.getMinutes();
datum=hh+':'+mi+' '+dd+'.'+mm+'.'+yy ;
sx='';
da='';
li= 0;
li2=0;
dx=dd;
var day = 1 ;
day=now2.getDay();
//alert(hh);

if((hh==19)&&(mi>=00)){li=1;}//Udalosti
 
if((day!=0)&&(day!=6))//vse mimo nedele a soboty
{
 if((hh== 9)&&(mi<=06)){li=1;}//zpravy
 if((hh==12)&&(mi<=30)){li=1;}//zpravy
 if((hh==15)&&(mi<=06)){li=1;}//zpravy
 //if (day!=2)
 //if((hh==16)&&(mi<=06)){li=1;}//zpravy
 if((hh==17)&&(mi>=55)){li=1;}//pocasi
 if((hh==18)&&(mi<=30)){li=1;}//vecernik
 if((hh==21)&&(mi<=25)){li2=1;}//komentare udalosti
 
 if (day!=2)
 if (day!=5)
 {//Streda
 if((hh==21)&&(mi>=30)){li=1;}//komentare udalosti
 }
}
//if((hh==20)&&(mi<=45)){li4=1;}//Studio fotbal

if(day==1)//Pondeli
{
 if (hh==17)           {li=1;}//Kluci v akci az-kVIZ
 if((hh==18)&&(mi<=45)){li=1;}//
 if((hh==19)&&(mi>=00)){li=1;}//Udalosti
 if (hh==21)           {li=1;}//Kouzlo afriky / Reporteri
//if (hh==22)           {li=1;}//na stope //udalosti komentare
 
 //if((hh==16)&&(mi>=30)){li2=1;}//ct2
 //if (hh==17)           {li2=1;}//ct2
 //if (hh==18)           {li2=1;}//ct2
 //if (hh==19)           {li2=1;}//ct2
 if((hh==19)&&(mi<=5)){li2=1;}//zpravy ve znakove reci
 //if((hh==20)&&(mi>=50)){li2=1;}//Pripad pro odbucmana
 //if((hh==21)&&(mi<=15)){li2=1;}//Knizni svet

}
if(day==2)//Utery
{
 if((hh==17)){li=1;}
 if((hh==18)){li=1;}
 if((hh==19)&&(mi>=00)){li=1;}//Udalosti
 if((hh==21)&&(mi>=00)){li=1;}//Trinacta komnata
//if((hh==22)){li=1;}//na stope //udalosti komentare

 if((hh==16)&&(mi>=25)){li2=1;}//ct2
 if (hh==17)           {li2=1;}//ct2
 if((hh==19)&&(mi<=5)){li2=1;}//zpravy ve znakove reci
}
if(day==3)//Streda
{
 if((hh==17)&&(mi>=30)){li=1;}//pocasi
 if((hh==18)){li=1;}//Vecernik, Ceske hlavy, Pod poklickou
 if((hh==19)&&(mi>=00)){li=1;}//Udalosti

 if((hh==18)&&(mi>=10)){li2=1;}//ct2
 if((hh==19)&&(mi<=10)){li2=1;}//zpravy ve znakove reci
}
if(day==4)//Ctvrtek 
{
 if((hh==17)&&(mi>=15)){li=1;}
 if((hh==18)&&(mi<=30)){li=1;}
//if((hh==21)&&(mi>=45)){li=1;}//Zito
 if((hh==21)&&(mi<=30)){li=1;}//Vypadas skvele
//if (hh==22)           {li=1;}//POKR 
//f((hh==22)&&(mi<=30)){li=1;}//Vypadas skvele

//if((hh==15)&&(mi>=45)){li2=1;}//ct2 zruseno
  if (hh==18)           {li2=1;}//ct2 zruseno
//if (hh==19)           {li2=1;}//ct2 zruseno
  if((hh==19)&&(mi<=10)){li2=1;}//zpravy ve znakove reci
}
if(day==5)//Patek
{
 if((hh==16)&&(mi<=30)){li=1;}//tykladlo
 if (hh==17)           {li=1;}//nemam praci
 if((hh==18)&&(mi<=35)){li=1;}//vecernik
 if((hh==21)&&(mi>=45)){li=1;}//13 komnata
 if((hh==22)&&(mi<=45)){li=1;}//13 komnata + Uvolni se

  if((hh==18)&&(mi<=35)){li2=1;}//Babylon
  if((hh==19)&&(mi<=10)){li2=1;}//zpravy ve znakove reci
//if((hh==20)&&(mi>=50)){li2=1;}//Krasny ztraty
  if((hh==21)&&(mi<=30)){li2=1;}//Udalosti kometare
  if((hh==21)&&(mi>=30)){li2=1;}//Na plovarne
//if (hh==22)           {li2=1;}//Ladi neladi?
}
if (day==6)//Sobota
{
if (hh==12){li=1;}
if((hh==13)&&(mi<=05)){li=1;}//zpravy
if((hh==17)&&(mi>=55)){li=1;}//pocasi
if((hh==18)&&(mi<=06)){li=1;}//zpravy
if((hh==23)&&(mi<=15)){li=1;}//zpravy

if((hh==12)&&(mi>=30)){li2=1;}//GP
if((hh==12)&&(mi>=45)){li2=0;}//GP end
if((hh==14)&&(mi>=50)){li2=1;}//Styl
if((hh==15)&&(mi<=45)){li2=0;}//Styl
if((hh==19)&&(mi>=40)){li2=1;}//Styl
}
if (day==0)//Nedele
{
if(hh==12){li=1;}
//if((hh==13)&&(mi<=10)){li=1;}//zpravy a OVM2 /bezi to na CT24
if((hh==16)&&(mi>=40)){li=1;}
if (hh==17){li=1;}
if((hh==18)&&(mi<=10)){li=1;}//zpravy

if((hh==18)&&(mi>=45)){li2=1;}//GP
if((hh==19)&&(mi<=15)){li2=1;}//GP end
}
if((hh==19)&&(mi<=59)&&(mi>=15)){li=1;}//udalosti
//if((hh==20)&&(mi<=09)){li=1;}
if(hh<= 10){dd=dd-1;hh=24;addDay(now2,-1);}//zde je chyba pouze prvni den v mesici
day=now2.getDay();
//start==1 = po startu automatika
//alert('test');
if (start==0)
{
  if (C3.checked==true)
  {
     if ((C5.checked==true)&&(li==1)){skoc2(hct1 )}
     else
     if ((CT2.checked==true)&&(li2==1)){skoc2(hct2)}
  //   else
  //   if ((CT4.checked==true)&&(li4==1)){skoc2(hct4)}
     else
     {skoc2(hct24)}
   }  
}
else
if ((C5.checked==true)&&(li==1)&&(lastx!=hct1)){skoc2(hct1 )}
else
if ((CT2.checked==true)&&(li2==1)&&(lastx!=hct2)){skoc2(hct2)}
//else
//if ((CT4.checked==true)&&(li4==1)&&(lastx!=hct4)){skoc2(hct4)}
     
lastli=li;

if(jak=='jen dnes')if(er==1){isin=0;window.setTimeout("zpravy_dle_hodiny('jen dnes');",60000);return;}//aby se nenaplnoval combobox a netrhala se obrazovka (je pro wm2003se)

if(dd==0)
{
if(mm== 2){dd=31}else
if(mm== 3){dd=28}else
if(mm== 4){dd=31}else
if(mm== 5){dd=30}else
if(mm== 6){dd=31}else
if(mm== 7){dd=30}else
if(mm== 8){dd=31}else
if(mm== 9){dd=31}else
if(mm==10){dd=30}else
if(mm==11){dd=31}else
if(mm==12){dd=30}else
if(mm== 1){dd=31;yy=yy-1}
mm=mm-1;
if(mm==0){mm=12}
}
ss='';
if(dd<10){ss=ss+'0'+dd}else{ss=ss+dd};
if(mm<10){ss=ss+'0'+mm}else{ss=ss+mm};
if(yy<10){ss=ss+'0'+yy}else{ss=ss+yy};
da=ss;

if(er==1){while (dnes.length>0)dnes.remove(0);}
sx=hcesko;
                                                 
                                             if(er==0){sx=sx+'<a title="Zive vysilani CT24" href="javascript:skoc2(&quot;'+hct24+'&quot;,true)">'+hct24+'</a>';}
                                                       else{var no = new Option();no.value="CT24"+da;no.text = hct24;        dnes.add(no,dnes.length);}
                                             if(er==0){sx=sx+', <a title="Zive vysilani CT24 (16:9)" href="http://wmtvs.com/live_TV_online_21083.htm"><blink><b>'+hct24+'(16:9)</b></blink></a>';}

//                                           if(er==0){sx=sx+', <a href="javascript:skoc2(&quot;mms://bcasta.livebox.tv/toptv?WMBitRate=256000&quot;,&quot;TOP&quot;)">TOP</a>';}                                         
                                             if(er==0){sx=sx+', <a href="javascript:skoc2(&quot;mms://89.235.30.186:8083/&quot;,&quot;Public TV&quot;)">Public TV</a>';}                                         
                                             if(er==0){sx=sx+', <a href="javascript:skoc2(&quot;mms://77.240.188.251/live&quot;,&quot;'+hbt+'&quot;,true)">'+hbt+'</a>';}
                                             if(er==0){sx=sx+', <a href="javascript:skoc2(&quot;http://servis.idnes.cz/stream/video.asp?p=ocko-tv-hq&quot;,&quot;'+hoc+'&quot;)">'+hoc+'</a>';} 
//                                           if(er==0){sx=sx+', <a href="javascript:skoc2(&quot;'+hpg24+'&quot;,&quot;'+hpg24+'&quot;)">'+hpg24+'</a>';}                                         
//new 24cz
//nejede na ppc     http://wmtvs.com/live_TV_online_21083.htm
//                                           if(er==0){sx=sx+', <a href="javascript:skoc2(&quot;mms://62.24.71.90/24.CZ&quot;,&quot;'+h24cz+'&quot;)">'+h24cz+'</a>';}
                                             if(er==0){sx=sx+', <a href="javascript:skoc2(&quot;http://netshow.atlas.cz/meteotv&quot;,&quot;'+hmtv+'&quot;)">'+hmtv+'</a>';}
                                             if(er==0){sx=sx+', <a href="javascript:skoc2(&quot;http://wmtvs.com/asx/live_TV_online_21083Z1.asx&quot;,&quot;Z1&quot;)"><blink>Z1</blink></a>';}                                         
                                             if(er==0){sx=sx+', <a href="javascript:skoc2(&quot;http://wmtvs.com/asx/live_TV_online_21083Z1N60.asx&quot;,&quot;Z1-60s&quot;)">Z1-60s</a>';}                                         
                                             if(er==0){sx=sx+', <a href="javascript:skoc2(&quot;http://wmtvs.com/asx/live_TV_online_21083Z1N.asx&quot;,&quot;Z1-NEWS&quot;)">Z1-NEWS</a>';}                                         
               
                                             //if(er==0){sx=sx+', <a href="http://wmTVs.com"><blink><b>'+hwmTVs+'</b></blink></a>';}
                                             if(er==0){sx=sx+' SK: <a href="javascript:skoc2(&quot;http://81.89.49.212/ta3live&quot;,&quot;TA3&quot;)">TA3</a>';}

                                             if(er==0){sx=sx+'<br>Svět: <a href="http://wmtvs.com/__index_Africa.htm" >Afrika</a>, ';}
                                             if(er==0){sx=sx+'<a href="http://wmtvs.com/__index_America.htm">Amerika</a>, ';}
                                             if(er==0){sx=sx+'<a href="http://wmtvs.com/__index_Asia.htm"   >Asie</a>, ';}
                                             if(er==0){sx=sx+'<a href="http://wmtvs.com/__index_Europe.htm" >Evropa</a>, ';}
                                             if(er==0){sx=sx+'<a href="http://wmtvs.com/__index_Oceania.htm">Oceanie</a>, ';}
//                                             if(er==0){sx=sx+' Tip:<a title="U.K." href="http://wmtvs.com/live_TV_online_99255.htm"><blink>Classic FM</blink></a>, ';}
//.                                          if(er==0){sx=sx+' Tip:<a title="USA" href="http://wmtvs.com/live_TV_online_116540.htm">ABC News</a>, ';}
//.                                          if(er==0){sx=sx+'<a title="Netherlands" href="http://wmtvs.com/live_TV_online_66535.htm"><blink>RTV Channel</blink></a>';}
//                                           if(er==0){sx=sx+', <a href="javascript:zpravy_dle_hodiny(&quot;jen dnes&quot;)">['+hre+']</a> ';}
//                                                       else{var no = new Option();no.value="CT1"+da;no.text = hcz;         dnes.add(no,dnes.length);}
//                                         sx=sx+'<a href="javascript:skoc2(&quot;mms://ct24stream.visual.cz/CT1-&quot;,&quot;'+hcz+'&quot;)" alt="Pouze pokud vysila zive CT1"><i>('+hc1+')</i></a> ';

sx=sx+'';
if(jak!='jen dnes')
{
if(er==1)co.value='<<-- JavaScript Init moment -->>';
if(er==0)dle_hodiny.innerHTML='---- JavaScript Init ----' ;
if(er==0)co2.innerHTML='<<-- JavaScript Init moment -->>';
//alert(sx);
var s=''  ;
var ms='' ;
var ys='' ;
var i=1   ;
var da=1 ;
dd=dx;
//if(hh< 20){dd--};
//if(hh>=20){addDay(now,1);}
var yy=now.getYear()-2000;
var mm=now.getMonth()+1;
var dd=((now.getDate()<10) ?"":"")+now.getDate();
if(dd<10){s='0'+dd}else{s=''+dd};
if(mm<10){ms='0'+mm}else{ms=''+mm};
if(yy<10){ys='0'+yy}else{ys=''+yy};
//alert('aha10');
while (udalosti.length>0)udalosti.remove(0);
while (udalostip.length>0)udalostip.remove(0);
while (udalostiu.length>0)udalostiu.remove(0);
while (udalostio.length>0)udalostio.remove(0);
while (udalostia.length>0)udalostia.remove(0);
while (udalostic.length>0)udalostic.remove(0);
while (udalostit.length>0)udalostit.remove(0);
while (udalostir.length>0)udalostir.remove(0);
while (udalostig.length>0)udalostig.remove(0);
while (udalosti4.length>0)udalosti4.remove(0);
while (udalosti9.length>0)udalosti9.remove(0);
while (udalostie.length>0)udalostie.remove(0);
while (udalostik.length>0)udalostik.remove(0);
//while (udalostis.length>0)udalostis.remove(0);
if(er==0)
{
if (document.all) {
  var arg1=udalosti.length+1;
  var arg2=0;
//  alert(0)
}else{
  var arg1=null;
  var arg2=udalosti.options[0];
//  alert(1)
}
}

var no = new Option();no.value=s+ms+ys;no.text = hvyb; udalosti .add(no,udalosti.length);
var no = new Option();no.value=s+ms+ys;no.text = hvyb; udalostip.add(no,udalostip.length);
var no = new Option();no.value=s+ms+ys;no.text = hvyb; udalostiu.add(no,udalostiu.length);
var no = new Option();no.value=s+ms+ys;no.text = hvyb; udalostio.add(no,udalostio.length);
var no = new Option();no.value=s+ms+ys;no.text = hvyb; udalostia.add(no,udalostia.length);
var no = new Option();no.value=s+ms+ys;no.text = hvyb; udalostic.add(no,udalostic.length);
var no = new Option();no.value=s+ms+ys;no.text = hvyb; udalostit.add(no,udalostit.length);
var no = new Option();no.value=s+ms+ys;no.text = hvyb; udalostir.add(no,udalostir.length);
var no = new Option();no.value=s+ms+ys;no.text = hvyb; udalostig.add(no,udalostig.length);
var no = new Option();no.value=s+ms+ys;no.text = hvyb; udalosti4.add(no,udalosti4.length);
var no = new Option();no.value=s+ms+ys;no.text = hvyb; udalosti9.add(no,udalosti9.length);
var no = new Option();no.value=s+ms+ys;no.text = hvyb; udalostie.add(no,udalostie.length);
var no = new Option();no.value=s+ms+ys;no.text = hvyb; udalostik.add(no,udalostik.length);
//var no = new Option();no.value=s+ms+ys;no.text = hvyb; udalostis.add(no,udalostis.length);

//alert(hhi)
  var ne =new Date();ne .setDate(1);ne .setMonth(2);ne .setYear (2006);
  var ne2=new Date();ne2.setDate(11);ne2.setMonth(1);ne2.setYear (2006);
  var ne3=new Date();ne3.setDate(4);ne3.setMonth(2);ne3.setYear (2006);
  var ne4=new Date();ne4.setDate(9);ne4.setMonth(1);ne4.setYear (2006);
  var ne5=new Date();ne5.setDate(12);ne5.setMonth(0);ne5.setYear (2006);
  var ne6=new Date();ne6.setDate(20);ne6.setMonth(4);ne6.setYear (2006);
  var neOVM=new Date();neOVM.setDate(29);neOVM.setMonth(3);neOVM.setYear (2007);
  var jo1=new Date();jo1.setDate(11);jo1.setMonth(5);jo1.setYear (2006);
  var jon=new Date();jon.setDate(01);jon.setMonth(5);jon.setYear (2006);
  var od4=new Date();od4.setDate(5);od4.setMonth(10);od4.setYear (2006);
 // var ne6=new Date();ne6.setDate(16);ne6.setMonth(4);ne6.setYear (2006);
 // alert(ne6);
//var ne=new Date();ne.setDate(17);ne.setMonth(1);ne.setYear (2006);
  
for(a=1;a<hhi;a++)
{
// alert(99)
 addDay(now,-1);
 var yy=now.getYear();
 if(yy>=2000){yy=yy-2000;}
 if(yy>=100){yy=yy-100;}

 var mm=now.getMonth()+1;
 var dd=((now.getDate()<10) ?"":"")+now.getDate();
 if(dd<10){s='0'+dd}else{s=''+dd};
 if(mm<10){ms='0'+mm}else{ms=''+mm};
 if(yy<10){ys='0'+yy}else{ys=''+yy};
 //alert(ys)
 //alert(now.getDay())
 da=now.getDay();
 ///if(er==0)co.innerHTML='---- JavaScript Init '+da+'----' ;

 if((dd==24)&&(mm==12))
 {}
 else
 { 
  if((dd!=27)||(mm!=1)||(yy!=6)){                                                                                    
  var no = new Option();no.value=s+ms+ys;no.text = s+'.'+ms+'.20'+ys ;udalosti.add(no,udalosti.length)    //Udalosti
                                          }
  if (da==6)
  if (now >= ne2)
  if((dd!=20)||(mm!=5)||(yy!=6))
  {var no = new Option();no.value=s+ms+ys;no.text = s+'.'+ms+'.20'+ys ;udalostia.add(no,udalostia.length);}
  
  
  if (da==6)
  if((dd!=11)||(mm!=2)||(yy!=6))
  if((dd!=18)||(mm!=2)||(yy!=6))
  if((dd!=25)||(mm!=2)||(yy!=6))
  if((dd!=10)||(mm!=3)||(yy!=7))
  if((dd!=17)||(mm!=3)||(yy!=7))
  if((dd!=24)||(mm!=3)||(yy!=7))
  {var no = new Option();no.value=s+ms+ys;no.text = s+'.'+ms+'.20'+ys ;udalostig.add(no,udalostig.length);}//Game age

  if (da==0){var no = new Option();no.value='MediaSvetCT24-'+s+ms+ys;no.text = s+'.'+ms+'.20'+ys ;udalosti9.add(no,udalosti9.length);}

  
  if (da==0)
  if((dd!=31)||(mm!=12)||(yy!=6))
    {var no = new Option();no.value=s+ms+ys;no.text = s+'.'+ms+'.20'+ys ;udalostit.add(no,udalostit.length);}//objektiv
  if (da==1)
  if((dd!=1)||(mm!=1)||(yy!=7))
  if((dd!=25)||(mm!=12)||(yy!=6))
  {var no = new Option();no.value=s+ms+ys;no.text = s+'.'+ms+'.20'+ys ;udalostir.add(no,udalostir.length);}//reporteri CT
  if((dd!=13)||(mm!=2)||(yy!=6))
  if (da==2){var no = new Option();no.value=s+ms+ys;no.text = s+'.'+ms+'.20'+ys ;udalostic.add(no,udalostic.length);}//cerne ovce

  if (yy==06)
  if (da==5)
  if (mm>=4)
  if((dd!=7)||(mm!=4)||(yy!=6))
  if((dd!=18)||(mm!=4)||(yy!=6))
  if((dd!=25)||(mm!=4)||(yy!=6))
  {var no = new Option();no.value=s+ms+ys;no.text = s+'.'+ms+'.20'+ys ;udalostik.add(no,udalostik.length);}//13 komnata
  
  if (yy>=07)
  if (da==5)
  {var no = new Option();no.value=s+ms+ys;no.text = s+'.'+ms+'.20'+ys ;udalostik.add(no,udalostik.length);}//13 komnata
  
//  if (now >= od4)
//  {var no = new Option();no.value=s+ms+ys;no.text = s+'.'+ms+'.20'+ys ;udalostis.add(no,udalostis.length);}//Studio fotbal
 
  //if (now >= ne)
  if (yy>=6)
  if((dd!=10)||(mm!=2)||(yy!=6))
  if (da==5){var no = new Option();no.value=s+ms+ys;no.text = s+'.'+ms+'.20'+ys ;udalostiu.add(no,udalostiu.length);}//uvolnetese prosim
  
  if((dd!=17)||(mm!=4)||(yy!=6))
  if((dd!=27)||(mm!=1)||(yy!=6))
  if((da!=6)&&(da!=0)){
             var no = new Option();no.value=s+ms+ys;no.text = s+'.'+ms+'.20'+ys ;udalostip.add(no,udalostip.length);//udalosti komentare
             var no = new Option();no.value=s+ms+ys;no.text = s+'.'+ms+'.20'+ys ;udalostie.add(no,udalostie.length);//ekonomika
                      }
  if((dd!=8)||(mm!=4)||(yy!=7))
  if (yy>=06)
  {
  if((dd!=16)||(mm!=4)||(yy!=6))
  {
  if((dd!=31)||(mm!=12)||(yy!=6))
  {
    
  if (da==0){
  if (now <= neOVM)
   {
   var no = new Option();no.value=s+ms+ys;no.text = s+'.'+ms+'.20'+ys ;udalostio.add(no,udalostio.length);
   }
   else
   {
   var no = new Option();no.value=s+ms+ys;no.text = s+'.'+ms+'.20'+ys ;udalostio.add(no,udalostio.length);
   }
  }
    if ((now <= ne6)||(now >= jo1))
     if (da==0){var no = new Option();no.value=s+ms+ys;no.text = s+'.'+ms+'.20'+ys ;udalosti4.add(no,udalosti4.length);}
   }
  }
  else
  {
  if (da==6){var no = new Option();no.value='OVM1-'+s+ms+ys;no.text = s+'.'+ms+'.20'+ys ;udalostio.add(no,udalostio.length);}
  if (now <= ne6)
  if (da==6){var no = new Option();no.value='OVM2-'+s+ms+ys;no.text = s+'.'+ms+'.20'+ys ;udalosti4.add(no,udalosti4.length);}
  }
  }
  else
  {if (da==0){var no= new Option();no.value='OVMZpravy1200-'+s+ms+ys;no.text = s+'.'+ms+'.20'+ys ;udalostio.add(no,udalostio.length);}
 }
}
}
}
else
{
  
  //if(jak!='jen dnes'
  if (1>=iev.indexOf('MSIE 4'   ))
  {
  window.setTimeout("zpravy_dle_hodiny('jen dnes');",60000);
  }
}
if(er==0){
 if(sx!='')
 if(dle_hodiny.innerHTML!=sx){dle_hodiny.innerHTML=sx;}
         }
  
if(jak=='jen dnes'){isin=0;return};         
if (C3.checked==true){
if(er==1){co.value=bkt;}
else     {if(co2.innerHTML!=bkt)co2.innerHTML=bkt;}

}
else
{
if(er==1){co.value=hvy;}
else     {co2.innerHTML=hvy;}
}
isin=0;
//co.focus();
}
//udalostip.options=udalosti.options

zpravy_dle_hodiny();
start=1;
//try{dat.value=datum;}catch(e){};
if (1>=iev.indexOf('MSIE 4'   ))
{
window.setTimeout("zpravy_dle_hodiny('jen dnes');",60000);
}
function ClipPlayState(NewState)
{
state=NewState;
//im.referer=hlaska;
//if (state== 3)im.src='images/bt_play.gif';
//if (state==6)im.src='images/bt_load.gif&';
sp();
}

function errorp()
{
try
{
  error_count=error_count+1;
  window.setTimeout("skoc2('"+hct24+"')",1000);
}catch(e)
{
  alert(e.message)
};

}

var blink_on       = "yellow"    ;
var blink_off      = "white" ;
var blink_interval = 300     ;

function blink()
{
try{
  var a = document.all.tags("blink");
  if (a.length > 0)
  {
  for (var x = 0; x < a.length; x++)
    {
    if (a[x].style.color == blink_off)
    a[x].style.color = blink_on
    else
    a[x].style.color = blink_off ;
    }
  window.setTimeout("blink()",blink_interval);
  }
}catch(e){};
}
try{blink();}catch(e){};

//-->
