function openWindow() {
window.open("","info",'toolbar=0,location=0,scrollbars=0,width=540,height=280,resizable=0,top=20,left=20');
}

var browser = null
if (document.all)
	browser = 'ie' 
if (!document.all && document.getElementById)
	browser = 'nn6'

function showPhoto(x,y,file,comment,close)
{
	var w = screen.availWidth||screen.width
	var h = screen.availHeight||screen.height
	var move_win = 0
	wx = x + 1; wy = y + 1;
	h -= 0; w -= 0;
	if (wx>w) { wx = w; move_win=1 }
	if (wy>h) { wy = h; move_win=1 }
	if (!comment) {	comment = '' }
	file = img+""+file
	var data_close = ""
	if (close==1)
		data_close ="onClick='window.close()' style='cursor: hand;'"
	var data = "<HTML><head><meta http-equiv=content-type content=text/html; charset=windows-1250><title>"+comment+"</title><LINK rel='StyleSheet' href='http://erik004.cz/lucaffepoint/css-js/lucaffepoint.css' type='text/css'></head><BODY><DIV align=center><IMG SRC='"+file+"' width="+x+" height="+y+" border=0 "+data_close+" alt='Kliknutím zavřete obrázek'></DIV></BODY></HTML>"
	var aa = window.open("", 'photo', 'resizable,scrollbars=0,menubar=0,width=' + wx + ',height=' + wy);
	if (move_win==1) { aa.moveTo(0,0) }
	aa.document.write(data)
	aa.document.close();
	aa.focus();
}

function showFoto(x,y,file,comment,close)
{
	var w = screen.availWidth||screen.width
	var h = screen.availHeight||screen.height
	var move_win = 0
	wx = x + 1; wy = y + 1;
	h -= 0; w -= 0;
	if (wx>w) { wx = w; move_win=1 }
	if (wy>h) { wy = h; move_win=1 }
	if (!comment) {	comment = '' }
	file = img+""+file
	var data_close = ""
	if (close==1)
		data_close ="onClick='window.close()' style='cursor: hand;'"
	var data = "<HTML><head><meta http-equiv=content-type content=text/html; charset=windows-1250><title>"+comment+"</title><LINK rel='StyleSheet' href='http://erik004.cz/lucaffepoint/css-js/lucaffepoint.css' type='text/css'></head><BODY><DIV align=center><IMG SRC='"+file+"' width="+x+" height="+y+" border=0 "+data_close+" alt='Kliknutím zavřete obrázek'></DIV></BODY></HTML>"
	var aa = window.open("", 'photo', 'resizable,scrollbars=0,menubar=0,width=' + wx + ',height=' + wy);
	if (move_win==1) { aa.moveTo(0,0) }
	aa.document.write(data)
	aa.document.close();
	aa.focus();
}

function show_hide(div1, div2) {
       document.getElementById(div1).style.display = "none";
       document.getElementById(div2).style.display = "";
       return false;
}


var show_time=false;
var timerID=null;

function stop(){
  if (show_time){
      clearTimeout(timerID);
      document.clock.date_time.value=" ";
  }
  show_time=false;
}

function start(form){
  var today=new Date();
  var display_value ="  " + today.getHours()
  if(today.getMinutes() < 10){
      display_value+=":0" + today.getMinutes();
  }
  else{
      display_value+=":" + today.getMinutes();
  }
  if (today.getSeconds() < 10){
      display_value+=":0" + today.getSeconds();
  }
  else{
      display_value+=":" + today.getSeconds();
  }
  if(today.getHours()>=12){
      display_value+="  "
      /* Here we have a variable called mygreeting where
        you can store somthing like this: 
        mygreeting ="Good Morning!"; */
  }
  else{
      display_value+="  "
      /* Now set mygreeting to:
        mygreeting ="Good Afternoon!"; */
  }
  display_value += "dne  " + today.getDate() + ". "  +
      (today.getMonth()+1) + ". " + today.getYear();
      document.clock.date_time.value=display_value;
      timerID=setTimeout("start()",100);
      show_time=true;
      /* Here have an alert() method do the following:
        alert(mygreeting); */
}