<!--

	function showFlash(movie, name, width, height) {
		document.write('<object classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" codebase="http://fpdownload.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,0,0" width="' + width + '" height="' + height + '" id="' + name + '" align="middle">');
		document.write('<param name="allowScriptAccess" value="sameDomain" />');
		document.write('<param name="movie" value="' + movie + '" />');
		document.write('<param name="quality" value="high" />');
		document.write('<param name="bgcolor" value="#ffffff" />');
		document.write('<embed src="' + movie + '" quality="high" bgcolor="#ffffff" width="' + width + '" height="' + height + '" name="' + name + '" align="middle" allowScriptAccess="sameDomain" type="application/x-shockwave-flash" pluginspage="http://www.macromedia.com/go/getflashplayer" />');
		document.write('</object>');
	}

	function newImage(arg) {
		if (document.images) {
			rslt = new Image();
			rslt.src = arg;
			return rslt;
		}
	}
	
	function changeImages() {
		if (document.images && (preloadFlag == true)) {
			for (var i=0; i<changeImages.arguments.length; i+=2) {
				document[changeImages.arguments[i]].src = changeImages.arguments[i+1];
			}
		}
	}

	function layerVisibility (id, vis) {
		document.getElementById(id).style.visibility=vis;
	}

	function changeLayerVisibility (id) {
		if (document.getElementById(id).style.display == "none") {
			document.getElementById(id).style.display = "block";
		} else {
			document.getElementById(id).style.display = "none";
		}
	}

	function changeBackground(id, bgColor) {
		document.getElementById(id).style.background = bgColor;
	}

	function changeBackgroundImage(id, bgImageURL) {
		document.getElementById(id).style.background = "url('" + bgImageURL +"')";
	}

	function img_popup(kep, width, height) {
		wnd = popUp("img_popup.php?kep=" + kep,"wnd", height, width);
	}

	function popUp(url, windowName, height, width) {
		var wnd = window.open(url, windowName, "height="+height+",width="+width+",status=no,menubar=no,resizable=no,directories=no,locationbar=no");
		wnd.focus();
	}

	function popUpScroll(url, windowName, height, width) {
		var wnd = window.open(url, windowName, "height="+height+",width="+width+",status=no,menubar=no,resizable=no,directories=no,locationbar=no,scrollbars=yes");
		wnd.focus();
	}

	function popUpTimeOut(url, windowName, height, width, msec) {
		var tid = window.setTimeout("popUp("+url+","+windowName+","+height+","+width+")",msec);
	}

	function popUpResizable(url, windowName, height, width) {
		var wnd = window.open(url, windowName, "height="+height+",width="+width+",status=yes,menubar=no,resizable=yes,directories=no,locationbar=yes,scrollbars=yes");
		wnd.focus();
	}

	function imagePick(target_field, target_preview, _x, _y) {
		var pickerWindow = popUp("webutils/image_picker.php?trgt_fld="+target_field+"&trgt_prw="+target_preview+"&_x="+_x+"_y="+_y, "pickerWindow", "120", "320");
	}

	function filePick() {
		var pickerWindow = popUp("webutils/file_picker.html", "pickerWindow", "200", "100");
	}

	function clock() {
		var runTime = new Date();
		var hours = runTime.getHours();
		var minutes = runTime.getMinutes();
		var seconds = runTime.getSeconds();
		if (hours == 0) {
			hours = 12;
		}
		if (hours <= 9) {
			hours = "0" + hours;
		}
		if (minutes <= 9) {
			minutes = "0" + minutes;
		}
		if (seconds <= 9) {
			seconds = "0" + seconds;
		}
		movingtime = hours + ":" + minutes + ":" + seconds;
		if (document.layers) {
			document.layers.clocklayer.document.write(movingtime);
			document.layers.clocklayer.document.close();
		}
		else {
			document.all.clocklayer.innerHTML = movingtime;
		}
		setTimeout("clock()", 1000)
	}

	// char converter
	/////////////////
	
	function fromCode(code) {
		return String.fromCharCode(code);
	}
	
	function convert(text) {
		flood = 0;
		while (text.indexOf("&#") != -1) {
			i = text.indexOf("&#") + 2;
			cserelendo = parseInt(text.substring(i,i+3));
			mire = fromCode(cserelendo);
			mit = text.substring(i-2,i+4);
			text = text.replace(mit, mire);
		}
		return text;
	}
	
	function toCode(code) {
		return code.charCodeAt(0);
	}
	
	function convertBack(text) {
	
		stdChars = "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVXYZ0123456789 -!@#$%^&*(),./;'[]\?:{}|+_~";
		
		i = 0;
		while (i<text.length && !(i>1000)) {
			if (stdChars.indexOf(text.charAt(i)) < 0) {
				text = text.replace(text.charAt(i),"&#" + toCode(text.charAt(i)) + ";");
				i += 5;
			}
			i += 1;
		}
	
		return text;
	}
	
	
	// regisztracio
	///////////////

	function chkMail(mail) {
		var filter  = /^([a-zA-Z0-9_\.\-])+\@(([a-zA-Z0-9\-])([a-zA-Z0-9\-])+\.)+([a-zA-Z0-9]{2,4})+$/;
		if (filter.test(mail)) {
			return true;
		} else {
			return false;
		}
	}

	function isNum(sText) {
		var ValidChars = "0123456789";
		var IsNumber = true;
		var Char;
		
		for (i = 0; i < sText.length && IsNumber == true; i++) { 
			Char = sText.charAt(i); 
			if (ValidChars.indexOf(Char) == -1) {
				IsNumber = false;
			}
		}
		return IsNumber;
	}
	
	function isFloat(sText) {
		var ValidChars = "0123456789,.";
		var IsNumber = true;
		var Char;
		
		for (i = 0; i < sText.length && IsNumber == true; i++) { 
			Char = sText.charAt(i); 
			if (ValidChars.indexOf(Char) == -1) {
				IsNumber = false;
			}
		}
		return IsNumber;
	}

	function getRadioValue(radioArray) {
		var res = null;
		for (i = 0; i < radioArray.length; i++) {
			if (radioArray[i].checked) {
				res = radioArray[i].value;
				break;
			}
		}
		return res;
	}
	
	// classcserelgeto
	//////////////////
	
	function changeClass(id, className) {
		obj = document.getElementById(id);
		if (obj) obj.className = className;
	}

//-->
