// JavaScript Document
//error support
function error(error){
	alert(error);
}

function popWin1(page, wi, he, wi2, he2) {

	w = screen.width;
	h = screen.height;
	sx = w/2-wi2;
	sy = h/2-he2;
	win = window.open(page,'pic_win','status=no,resizable=no,scrollbars=no,toolbar=no,location=no,directories=no,menubar=no,width='+wi+',height='+he+',top='+sy+',left='+sx+',screenX='+sx+',screenY='+sy+'');
	win.resizeTo(wi+7, he+50);
	win.moveTo(sx, sy);
	win.focus();
}

function popWin2(page, win_id, wi, he, wi2, he2) {

	w = screen.width;
	h = screen.height;
	sx = w/2-wi2;
	sy = h/2-he2;
	var win_za_snimka = window.open(page,win_id,'status=no,resizable=no,scrollbars=no,toolbar=no,location=no,directories=no,menubar=no,width='+wi+',height='+he+',top='+sy+',left='+sx+',screenX='+sx+',screenY='+sy+'');
	win_za_snimka.resizeTo(wi+7, he+50);
	win_za_snimka.moveTo(sx, sy);
	win_za_snimka.focus();
}

function win_snimki_close() {
	var win_za_snimki;
	win_za_snimki.close();
}

function popWin(page, wi, he, wi2, he2) {

	w = screen.width;
	h = screen.height;
	sx = w/2-wi2;
	sy = h/2-he2;
	win = window.open(page,'pic_win2','status=no,resizable=no,scrollbars=yes,toolbar=no,location=no,directories=no,menubar=no,width='+wi+',height='+he+',top='+sy+',left='+sx+',screenX='+sx+',screenY='+sy+'');
	win.resizeTo(wi+7, he+50);
	win.moveTo(sx, sy);
	win.focus();
}


function show_hide(divName) {
	if (document.getElementById) {
		obj=document.getElementById(divName)
	} else if (document.all) {
		obj=document.all[divName]
	}

	if (obj) {
		if (obj.style.display == "none") {
			obj.style.display = '';
		}
		else {
			obj.style.display = 'none';
		}
	}
}

