

function ukaz_alert(message, obj, skript) {
      document.getElementById("alert").style.display = "inline";
      document.getElementById("alert").style.height = document.body.scrollHeight;  //nastavime vysku, dle dokumentu
      document.getElementById("alert").style.width = document.body.clientWidth;
      
      document.getElementById("alert_text").innerHTML = message;
      
      
      document.getElementById("alert-spacer").style.height = (document.body.scrollTop + (document.body.clientHeight / 2) - 200);

      $('#overlay').css({
				backgroundColor:	"#000",
				opacity:			0.8,
				width:				$(document).width(),
				height:				$(document).height()
			}).fadeIn();
      
      document.getElementById("alert-close").onclick = function () {
         skryt("alert");
         if(skript == "submit") obj.submit();
         return false;
      }
       
      
      
      return false;
   }
   
   


   function skryt_alert() {
      $('#overlay').fadeOut();//function() { $('#overlay').remove(); });
			// Show some elements to avoid conflict with overlay in IE. These elements appear above the overlay.
			$('embed, object, select').css({ 'visibility' : 'visible' });
      document.getElementById("alert").style.display='none';
      return false;
   }
