// add as many or as few messages as you would like
var msg=new Array()
msg[0]="<CENTER>Vítejte na neoficiálních stránkách města Mirovice.</CENTER>";
msg[1]="<CENTER>Naše e-mailová adresa je \<a href='mailto:mirovice@seznam.cz?subject=Mirovice.zde.cz'>mirovice@seznam.cz</a>\</CENTER>";
msg[2]="<CENTER>v sekci '\<A href='../aktualne/aktualne.php'>aktuálně</A>\' naleznete novinky z&nbsp;našeho města a '\<A href='../mirovicko/root/h_home.html'>mirovický zpravodaj</A>\',</CENTER>";
msg[3]="<CENTER>slibujeme, že u nás získáte víc něž jen pouhé '\<A href='../zakl_info/zakl_info.htm'>Zakladní informace</A>\' o Mirovicíh,</CENTER>";
msg[4]="<CENTER>pochlubíme se vyčerpávající nabídkou '\<A href='../historie/historie.htm'>Historických faktů</A>\' ale i zdejších lidových pověstí,</CENTER>";
msg[5]="<CENTER>neopoměňte navštívit ani naši '\<A href='../galerie/galerie.html'>Obrazárnu</A>\', kde na Vás čekají desítky obrazků a fotografií,</CENTER>";
msg[6]="<CENTER>pro vyznavače naučných pochodů je zde také malý 'Turistický průvodce', </CENTER>";
msg[7]="<CENTER>rádi Vám poskytneme infomrace ze zdejší '\<A href='../farnost/farnost.htm'>Římskokatolické farnosti</A>\' a '\<A href='../farni_zp/root/h_home.html'>farního zpravodaje</A>\',</CENTER>";
msg[8]="<CENTER>a jistě se bude hodit i '\<A href='../sez_firm/sez_firm.htm'>Seznam obchodů, firem, veřejných zařízení a organizací</A>\' na Mirovicku,</CENTER>";
msg[9]="<CENTER>Vaše pocity, nápady nebo jiné vzkazy můžete psát do '\<A href='../guestbook/kniha.php'>Knihy návštěv</A>\'</CENTER>";
msg[10]="<CENTER>a další zajímavé odkazy '\<A href='../jih_net/odkazy.htm'>Jihočeského kraje</A>\', Vás zavedou z&nbsp;Mirovic zas o kus dál.</CENTER>";
msg[11]="<CENTER>a nakonec náš spřátelený server '\<A target=blank  href='http://fcmirovice.host.sk'>FC Dimmpl Mirovice</A>\', který je věnován zdejším fotbalovým fandům</CENTER>";
msg[12]="<CENTER>Takže nezapomeňte naší adresu: \"<A target=_top href='http://mirovice.zde.cz/'>www.mirovice.zde.cz</A>\"</CENTER>";
msg[13]="<CENTER>...</CENTER>"

// set your first set of colors.  Use as many or as few as you wish.
var colors1=new Array("#E0E0E0", "#E0E0E0", "#E0E0E0", "#D0D0D0", "#C0C0C0", "#B0B0B0", "#A0A0A0",
"#808080", "#707070", "#606060", "#505050", "#404040", "#303030","#202020", "#101010", "#000000")

//set your second set of colors
// *** must have exactly the same number of colors as the array above ***
var colors2=new Array("#D0D0D0", "D0D0D0", "D0D0D0", "#D0D0D0", "#C0C0C0", "#B0B0B0", "#A0A0A0",
"#808080", "#707070", "#606060", "#505050", "#404040", "#303030","#202020", "#101010", "#000000")

//set the height of the display in pixels
high=0;

//set the width of the display in pixels
wide=650;

//set the pixel coordinates for the upper left hand corner of the display
Xpos=0;
Ypos=0;

// move the display away from the edges of the background
pad=0;

// set the background color of the display
bgcol="d3d3d3";

//add a background image if you want.
// *** for no image, just leave empty quotes (ex. cellbg=""; ) ***
cellbg="";

// set the font
fntFam="tahoma,verdana,helvetica,arial";
fntSize=10;

// set how how many seconds you want the message to stay remain at totality.
pause=3;


// Do not edit these values below!!!

icolor=0;
mcolor=1;
imsg=0;
spWidth=wide-(2*pad);
totality=false;
glowing=true;
var theMsg="";
var cellcontent="";
pause=pause*1000;
if(cellbg.length>4){cellbg=" background="+cellbg}
else{cellbg="";}

function doPause(){
   totality=false; t=setTimeout("changecolor()",pause);
   }
function initiate(){
   getContentColor();
   getMsg();
   getCellContent();
   if(document.all){
   msgbg.innerHTML=cellcontent;
   msgfade.innerHTML=theMsg;
   msgbg.style.posLeft=Xpos;
   msgbg.style.posTop=Ypos;
   msgfade.style.posLeft=Xpos+pad;
   msgfade.style.posTop=Ypos+pad;
   t=setTimeout("changecolor()",50);}
   if(document.layers){
   document.msgbg.document.write(cellcontent);
   document.msgbg.document.close();
   document.msgfade.document.write(theMsg);
   document.msgfade.document.close();
   document.msgbg.left=Xpos;
   document.msgbg.top=Ypos;
   document.msgfade.left=Xpos+pad;
   document.msgfade.top=Ypos+pad;
   t=setTimeout("changecolor()",100);}
   }
function changecolor(){
   if(totality==true){doPause();}
   else{
   getMsg();
   getContentColor();
   if(document.all){
   msgfade.innerHTML=theMsg;
   t=setTimeout("changecolor()",50);}
   if(document.layers){
   document.msgfade.document.write(theMsg);
   document.msgfade.document.close();
   t=setTimeout("changecolor()",70);}
   }
   }
function getFadeColor(){
   icolor=icolor-1;
   if(mcolor==1){contentcolor=colors1[icolor];}
   else{contentcolor=colors2[icolor];}
   }
function getGlowColor(){
   icolor=icolor+1;
   if(mcolor==1){contentcolor=colors1[icolor];}
   else{contentcolor=colors2[icolor];}
   }
function changemsg(){
   if(imsg==msg.length-1){imsg=0; mcolor=1;}
   else if(imsg != msg.lenght-1 && mcolor==1){imsg=imsg+1; mcolor=0;}
   else{imsg=imsg+1; mcolor=1;}
   }
function getContentColor(){
   if(icolor==colors1.length-1 && glowing==true){
   getFadeColor(); glowing=false; totality=true;}
   else if(icolor < colors1.length && glowing==true){
   getGlowColor();}
   else if(icolor < 1 && glowing==false){changemsg(); getGlowColor(); glowing=true;}
   else{getFadeColor();}
   }
function getMsg() {
   theMsg="<span style='font-size:"+fntSize+"pt; font-family:"+fntFam+"; width:"+spWidth+";'>"
   theMsg+="<B><font color="+contentcolor+">"+msg[imsg]+"</font></B> "
   theMsg+="</span>"
   }
function getCellContent(){
   cellcontent="<TABLE height="+high+
   " width="+wide+" bgcolor="+bgcol+" cellpadding=0 cellspacing=0><TR><TD"+cellbg+"> </TD></TR></TABLE>"}