<!--
var boxesHideTimeout=null;
var boxesHideDelay=2000;
var numChars = new RegExp("[0-9]+");
var smallChars = new RegExp("[a-záéíóöőúüű]+");
var bigChars = new RegExp("[A-ZÁÉÍÓÖŐÚÜŰ]+");
var iranyitoszamChars = new RegExp("[0-9]");
var telefonChars = new RegExp("[0-9\(\)\/\+\-]");
var emailChars = new RegExp("[a-zA-Z0-9\-\.\_\@]");
var notEmailChars = new RegExp("[^\@]+");
var datumChars = new RegExp("[0-9\-\.]");
var calendarDefaultClasses = new Array();
//---------------------------------------------------------
function submitenter(myfield,e)
	{
	var keycode;
	if (window.event) keycode = window.event.keyCode;
	else if (e) keycode = e.which;
	else return true;
	if (keycode == 13)
		{
		myfield.form.submit();
		return false;
		}
	else

		return true;
	}

//---------------------------------------------------------
function dataArraySelect(dataArray,searchedField,searchedValue)
	{
	var a;
	var returnArray=new Array();
	for (a=0;a<dataArray.length;a++)
		{
		if (dataArray[a][searchedField]==searchedValue)
			{
			returnArray.push(dataArray[a]);
			}
		}
	return returnArray;
	}
//---------------------------------------------------------
function activateDates(dateTdObjects)
{
var a,oTd,testArray;
for (a=0;a<dateTdObjects.length;a++)
	{
	oTd=document.getElementById(dateTdObjects[a]);
	if (oTd)
		{
		testArray=dataArraySelect(calendarDefaultClasses,0,dateTdObjects[a]);
		if (testArray.length==0)
			{
			calendarDefaultClasses.push(new Array(dateTdObjects[a],oTd.className));
			}
		oTd.className='active';
		}
	}
}
//---------------------------------------------------------
function deActivateDates(dateTdObjects)
{
var a,oTd,testArray;
for (a=0;a<dateTdObjects.length;a++)
	{
	oTd=document.getElementById(dateTdObjects[a]);
	if (oTd)
		{
		testArray=dataArraySelect(calendarDefaultClasses,0,dateTdObjects[a]);
		oTd.className=testArray[0][1];
		}
	}
}
//---------------------------------------------------------
function checkExprKey(sValidExpr,e)
/*
** reg exp alapján elfogadja vagy visszautasítja a leütött karaktert
**
** sValidExpr: valid regular expression
** nKeycode: pressed key
** sKeycode: character representation of pressed key
** last modification: 2005.02.08. by zizi
*/
	{
	var nKeycode;

	if (window.event) nKeycode = window.event.keyCode;
	else if (e) nKeycode = e.which;
	else return true;

	var sKeycode = String.fromCharCode(nKeycode);
	if ((nKeycode==8)||(nKeycode==0)||(sValidExpr.exec(sKeycode))) return true;

	return false;
}
//---------------------------------------------------------
function checkExprPaste(sValidExpr,e)
// 	onPaste="return checkExprPaste(telefonChars,event)" - Firefox alatt nem jó!!!


/*
** reg exp alapján elfogadja vagy visszautasítja a paste-elni kívánt tartalmat, ha az text
**
** sValidExpr: valid regular expression
** last modification: 2005.02.08.by zizi
*/
	{
	var i, j, s, w;


	if (window.event) s = window.clipboardData.getData("Text");
	else return true;

	j = s.length;
	for (i = 0; i < j; i++) {
		w = s.charAt(i);
		if (! sValidExpr.exec(w)) return false;
	}

	return true;
}

//---------------------------------------------------------

function setBoxesHideTimeout()
	{
	if (boxesHideTimeout)
		{window.clearTimeout(boxesHideTimeout);}
	boxesHideTimeout=window.setTimeout("hideAllBoxes()",boxesHideDelay);
	}
//---------------------------------------------------------

function windowOpen(url,windowName,windowWidth,windowHeight)
	{
	html = window.open(url,windowName,"resizeable=0,scrollbars=0,width="+windowWidth+",height="+windowHeight);
	//html.document.belepesForm.referrer.value=window.location;
	}
//---------------------------------------------------------
function onFormListChange(formList)
	{
	formList.options[formList.selectedIndex].style.backgroundColor='#FFCC00';
	}
//---------------------------------------------------------
function scrollWindowOpen(url,windowName,windowWidth,windowHeight)
	{
	html = window.open(url,windowName,"resizable=0,scrollbars=1,width="+windowWidth+",height="+windowHeight);
	}
//---------------------------------------------------------
function resizableWindowOpen(url,windowName,windowWidth,windowHeight)
	{
	html = window.open(url,windowName,"resizable=1,scrollbars=1,width="+windowWidth+",height="+windowHeight);
	}
//---------------------------------------------------------
function ablak(file,scroll,width,height,altname) {

    nagyablak = window.open('',altname,'top=0,left=0,toolbar=0,location=0,directories=0,status=0,menubar=0,scrollbars='+scroll+',resizable=1,width='+width+',height='+height);
    nagyablak.document.open();
    nagyablak.document.write("<html><head><title>Turizmus Online</title></head><body bgcolor=#ffffff leftmargin=0 topmargin=0 marginwidth=0 marginheight=0>");
    nagyablak.document.write("<div align=center><a href='javascript:window.close()'><img src='"+file+"' border='0' border-color=\"#000000\" alt='"+altname+"'></a></div>");
    nagyablak.document.write("</body></html>");
    nagyablak.document.close();
}
//---------------------------------------------------------
function MM_reloadPage(init) {
  if (init==true) with (navigator) {if ((appName=="Netscape")&&(parseInt(appVersion)==4)) {
    document.MM_pgW=innerWidth; document.MM_pgH=innerHeight; onresize=MM_reloadPage; }}
  else if (innerWidth!=document.MM_pgW || innerHeight!=document.MM_pgH) location.reload();
}
MM_reloadPage(true);
//---------------------------------------------------------

function MM_findObj(n, d) { //v4.0
  var p,i,x;  if(!d) d=document; if((p=n.indexOf("?"))>0&&parent.frames.length) {
    d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);}
  if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i<d.forms.length;i++) x=d.forms[i][n];
  for(i=0;!x&&d.layers&&i<d.layers.length;i++) x=MM_findObj(n,d.layers[i].document);
  if(!x && document.getElementById) x=document.getElementById(n); return x;
}
//---------------------------------------------------------

function MM_preloadImages() { //v3.0
  var d=document; if(d.images){ if(!d.MM_p) d.MM_p=new Array();
    var i,j=d.MM_p.length,a=MM_preloadImages.arguments; for(i=0; i<a.length; i++)
    if (a[i].indexOf("#")!=0){ d.MM_p[j]=new Image; d.MM_p[j++].src=a[i];}}
}
//---------------------------------------------------------

function MM_swapImage() { //v3.0
  var i,j=0,x,a=MM_swapImage.arguments; document.MM_sr=new Array; for(i=0;i<(a.length-2);i+=3)
   if ((x=MM_findObj(a[i]))!=null){document.MM_sr[j++]=x; if(!x.oSrc) x.oSrc=x.src; x.src=a[i+2];}
}
//---------------------------------------------------------

function MM_swapImgRestore() {
  var i,x,a=document.MM_sr; for(i=0;a&&i<a.length&&(x=a[i])&&x.oSrc;i++) x.src=x.oSrc;
}
// ----- ----- ----- ----- ----- ----- ----- -----
function ar_formaz(strObj)
	{
	var stringObject=String(strObj);
	var a;
	var returnString='';
	var counter=0;
	for (a=stringObject.length-1;a>=0;a--)
		{
		counter++;
		if (counter==4)
			{
			returnString=' '+returnString;
			counter=1;
			}
		returnString=stringObject.substr(a,1)+returnString;
		}
	return returnString;
	}
//---------------------------------------------------------
function showJobprofi(url, flag) {


    var cValue = getCookie( 'jobprofi' );

    if ( cValue == null ) {

    	setCookie( 'jobprofi', 1 );


    	if (flag===true) {

			bodytext=""+
			"<div style='margin: 20px; text-align: center;'>"+
			"<img src='/pic/jobprofi_logo.gif'><br>"+
			"<h1>Kedves Felhasználónk!</h1>"+
			"<p>Online álláshirdetéseinek feladását 2008. június 9-től a Professional Publishing Hungary Kft szakmai hírleveleink gyűjtőportálja, a JobProfi.hu szolgálja ki.</p>"+
			"<p><b>Álláshirdetését</b> a jobprofi.hu oldalon tudja feladni. A feladott hirdetések továbbra is változatlan feltételekkel jelennek meg az Ön által kiválasztott <b>szakmai hírportálon</b> és <b>szakmai hírlevelek</b><br>(<a href='http://www.turizmusonline.hu/'>www.turizmusonline.hu</a>, <a href='http://www.kreativ.hu/'>www.kreativ.hu</a>, <a href='http://www.medicalonline.hu/'>www.medicalonline.hu</a>, <a href='http://www.elelmiszer.hu/'>www.elelmiszer.hu</a>,  <a href='http://www.gyartastrend.hu/'>www.gyartastrend.hu</a>, <a href='http://www.vendegeshotel.hu/'>www.vendegeshotel.hu</a>)<br>Online álláshirdetések rovatában, valamint a <b>jobprofi.hu</b> oldalon egyaránt.</p>"+
			"<p>A JobProfi gyűjtőportál lehetővé teszi, hogy Ön ugyanazt az álláshirdetést egy időben, akár több szakmai hírlevélben is feltöltheti.</p>"+
			"<p>Egyszeri regisztráció után további álláshirdetéseihez már csak a megkapott jelszót kell használni.</p>"+
			"<p>Folytatáshoz kattintson <a href='"+url+"' target='jobprofi'>ide</a>!</p>"+
			"<p><a href='JavaScript:location.reload(true);'>« vissza</a></p>"+
			"</div>";

    	} else {

    		bodytext=""+
			"<div style='margin: 20px; text-align: center;'>"+
			"<img src='/pic/jobprofi_logo.gif'><br>"+
			"<h1>Kedves Felhasználónk!</h1>"+
			"<p>A Turizmusonline.hu online álláshirdetéseinek kezelését 2008. június 9-től a Professional Publishing Hungary Kft szakmai hírleveleink gyűjtőportálja, a JobProfi.hu szolgálja ki.</p>"+
			"<p>Folytatáshoz kattintson <a href='"+url+"' target='jobprofi'>ide</a>!</p>"+
			"<p><a href='JavaScript:location.reload(true);'>« vissza</a></p>"+
			"</div>";

    	}


		document.getElementById("jobprofiZone").innerHTML = bodytext;

    }
    else { window.open( url, 'jobprofi' ); }



}
//---------------------------------------------------------
function getCookie( NameOfCookie )
{
    if ( document.cookie.length > 0 )
    {
        begin = document.cookie.indexOf( NameOfCookie + "=" );
        if ( begin != -1 )
        {
            begin += NameOfCookie.length + 1;
            end = document.cookie.indexOf( ";", begin );
            if ( end == -1 ) { end = document.cookie.length; }
            return document.cookie.substring( begin, end );
        } else { return null;  }
    }
}

function setCookie( name, value ) {

	var exp = new Date ();
	exp.setTime( exp.getTime() + ( 1000 * 24 * 3600 * 1000 ) );
	document.cookie = name + "=" + escape( value ) + "; expires=" + exp.toGMTString() + "; path=/;";
}
//-->