        function centred_window_scroll(theURL,w,h) {
			meta_h = 40;

			wtop = Math.round((screen.height - h - meta_h) / 2) - meta_h;
			wleft = Math.round((screen.width - w) / 2);
			
			info = window.open(theURL, '', 'width=' + (w + 20) + ', height=' + (h + meta_h + 10) + ',resizable=no,scrollbars=1,status=0,top=' + wtop + ',left=' + wleft);
		}

        function centred_window_noscroll(theURL,w,h) {
			meta_h = 40;

			wtop = Math.round((screen.height - h - meta_h) / 2) - meta_h;
			wleft = Math.round((screen.width - w) / 2);
			
			info = window.open(theURL, '', 'width=' + (w + 20) + ', height=' + (h + meta_h + 10) + ',resizable=no,scrollbars=0,status=0,top=' + wtop + ',left=' + wleft);
		}

		function large_picture(nam, file, w, h) {

			meta_h = 50;

			wtop = Math.round((screen.height - h - meta_h) / 2) - meta_h;
			wleft = Math.round((screen.width - w) / 2);
	
			pic = window.open('', '', 'width=' + (w + 20) + ', height=' + (h + meta_h + 10) + ',resizable=yes,top=' + wtop + ',left=' + wleft);
			pic.document.open();
			pic.document.writeln('\
		<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"\
			"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">\
		\
		<html>\
		<head>\
		<meta http-equiv="Content-Type" content="text/html; charset=windows-1250">\
		<title>' + nam + '</title />\
		<style type="text/css">\
		BODY { margin: 0px; background: white; }\
		.popisek {TEXT-ALIGN: center; PADDING-TOP: 3px; VERTICAL-ALIGN: top; COLOR: white; FONT-FAMILY: Arial,Verdana; FONT-SIZE: 11px; FONT-WEIGHT: bold; BACKGROUND: url(http://beta.bbgbenda.com/images/footer_large_picture.jpg) no-repeat center 0px;"}\
		</style>\
		</head>\
		<body>\
		<center>\
		<table align="center">\
		<tr height="6">\
			<td></td>\
		</tr>\
		</table>\
		<a href="javascript:window.close();" title="Kliknutím na obrázek okno zavřete"><img src="' + file + '" width="' + w + '" height="' + h + '" alt="Kliknutím na obrázek okno zavřete" border="0"/></a>\
		</center>\
		<table align="center" width="100%">\
		<tr style="height: 40px;">\
			<td class="popisek">' + nam +'</td>\
		</tr>\
		</table>\
		</body>\
		</html>\
		');
			pic.document.close();
		}

	function uprDest(zem, idd, idz, named) {
		var poleIdDest = idd.split(";");
		var poleIdZem = idz.split(";");
		var poleNameDest = named.split(";");

		i = 0;
		j = 0;

		document.formular.destination.options.length = 0;
		document.formular.destination.options[0] = new Option("--- nerozhoduje --- ", 0, true, false);
		for(i=0;i<poleIdZem.length;i++){
			if (poleIdZem[i] == zem) {
				j++;
				document.formular.destination.options[j] = new Option(poleNameDest[i], poleIdDest[i], false, false);
			}
		}
	}
	

