    
    onload = function() {
        zmena_headeru(0, 1, 0);
    }
    
    var pocet_souboru = 5; 

    function zmena_headeru(obr, obr2, opacity){
             
        oldImage      = 'url(http://'+window.location.hostname+'/header/'+obr2+'.jpg)';
        newImage      = 'url(http://'+window.location.hostname+'/header/'+obr+'.jpg)';
        
        opacity += 0.01;
                
        document.getElementById('banner').style.backgroundImage  = oldImage;
        document.getElementById('banner').style.opacity          = opacity;
        if (window.ActiveXObject) {
        document.getElementById('banner').style.filter           = "alpha(opacity=" + opacity*100 + ")";
        }
      
        document.getElementById('banner2').style.backgroundImage = newImage;

         
        if(opacity>=1)
        {
          dalsi_obrazek = (obr2+1)%pocet_souboru;  
          opacity = 0;
          setTimeout("window.zmena_headeru("+obr2+","+dalsi_obrazek+","+opacity+")", 3000); //3000
        }
        else
        {
          setTimeout("window.zmena_headeru("+obr+","+obr2+","+opacity+")", 5);    //80     
        }
    } 
       
        var safari  = false;
        var opera   = false;
        var firefox = false;
        var agent   = navigator.userAgent.toLowerCase();
        
        if (agent.indexOf("safari") != -1){
        document.write('<link rel="stylesheet" type="text/css" href="http://'+window.location.hostname+'/style.css">');
        }
        else if(agent.indexOf("opera") != -1){
        document.write('<link rel="stylesheet" type="text/css" href="http://'+window.location.hostname+'/style_other.css">');
        }
        else if(agent.indexOf("mozilla") != -1){
        document.write('<link rel="stylesheet" type="text/css" href="http://'+window.location.hostname+'/style.css">');
        }

