function bejovoMappakAllitasa()	{	var elemLinks = jQuery("#menu_vertical_level").find("li[@class='menu_ver_item_active'],li[@class='menu_ver_item']");elemLinks.each(    function(p) {    	var nowObj = jQuery(this);    		nowObj.click(function() { var aktivObj = jQuery(".menu_ver_item_active");var aktivSzovegObj = aktivObj.find("span");aktivSzovegObj.text(aktivSzovegObj.text());aktivObj.removeClass("menu_ver_item_active");aktivObj.addClass("menu_ver_item");var szovegObj = nowObj.find("span");szovegObj.html('<strong>' + szovegObj.text() + '</strong>');nowObj.removeClass("menu_ver_item");nowObj.addClass("menu_ver_item_active");    });    }  );}function showFlash(movie, name, width, height, terkepId) {if (terkepId == null) {terkepId = "flash_terkep";}var terkepFlashDiv = jQuery("#" + terkepId);var message = '';message+='<object classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" codebase="http://fpdownload.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=7,0,0,0" width="' + width + '" height="' + height + '" id="' + name + '">';message+='<param name="movie" value="' + movie + '" />';message+='<param name="quality" value="high" />';message+='<param name="wmode" value="transparent" />';message+='<embed src="' + movie + '" quality="high" width="' + width + '" height="' + height + '" name="' + name + '" wmode="transparent" type="application/x-shockwave-flash" pluginspage="http://www.macromedia.com/go/getflashplayer" />';message+='</object>';terkepFlashDiv.html(message);}function showProgress(url, contentId, runOnEnd, messageCode, doNotClosePopup, modalE) {if (modalE == null) {modalE = true;}if (messageCode == null) {messageCode = 0;}var popup = Liferay.Popup({title: 'Betöltés',modal: modalE,width: 320,height: 75,noCenter: true,disableCloseWindow: true		});AjaxUtil.update('/ctk/keresProgressTartalom.jsp?messageCode=' + messageCode, popup, {onComplete: function(){Liferay.Popup.center();}});AjaxUtil.update(url, contentId, {onComplete: function(){if (runOnEnd) {runOnEnd();}if (doNotClosePopup != true) {Liferay.Popup.close(popup);}}});}function showMessageToUser() {setTimeout('showMessageToUserReal()', 100);}function showMessageToUserReal() {var popup = Liferay.Popup({title: '',modal: true,width: 600,height: 500,noCenter: false,disableCloseWindow: false		});AjaxUtil.update('/ctk/showMessageToUser.jsp', popup, {onComplete: function(){Liferay.Popup.center();}});}function forceChecked(checked, id) {document.getElementById(id).checked = checked;}function reloadKisBalMenu() {loadURLDynamicNotCached('/ctk/layout/modules/infoBoxBody.jsp', 'infoBoxMainDivId', true);}ctkAjaxPopupRunFunctionOnEnd = function(url, title, _width, _height, functionOnEnd) {if (title == null) {title = '';}var popup = Liferay.Popup({title: title,modal: true,width: _width,height: _height,noCenter: true});AjaxUtil.update(url, popup, {onComplete: function(){if (functionOnEnd) {functionOnEnd();}Liferay.Popup.center();}});}function centerThePopup() {  Liferay.Popup.center();}function centerThePopupDelayed() {setTimeout('centerThePopup();', 1000);}function loadTelKiadasResult(intoId, destId) {var actDate = new Date();// closepopup a vegen azert kell mert van egy confirm alatta amit nem zarhattunk be amig a knight rider le nem fut// mivel van showprogress igy azt is le kell zarni igy egy closepopup csak azt fogja bezarni ezert kell 2showProgress('/ctk/kredit/telKiadasResult.jsp?timeForNoCache=' + actDate.valueOf() + '&destId=' + destId, intoId, function() { closePopup();closePopup(); }, 1);}function showSaveProcess(crid, divid) {showProgress('/ctk/showImageSaveProcess.jsp?crid=' + crid, divid, checkUpdateSaveProcess(crid, divid), 2, true, false);}checkUpdateSaveProcess = function(crid, divid) { if (jQuery('#saveResult').val() == 'true') {// sikeres feltoltes//closePopup();setTimeout("location.href='/registration/reg_end'", 1000);} else {// meg nincs kesz a folyamatsetTimeout('updateSaveProcess(\'' + crid + '\',\'' + divid + '\')', 500);}}function updateSaveProcess(crid, divid) {AjaxUtil.update('/ctk/showImageSaveProcess.jsp?crid=' + crid, divid, {onComplete: function(){checkUpdateSaveProcess(crid, divid);}});}function loadURLDynamicNotCached(urlString, intoId, putAskSign) {var actDate = new Date();var askSign = '&';if (putAskSign) {askSign = "?";}jQuery('#' + intoId).load(urlString + askSign + 'timeForNoCache=' + actDate.valueOf());} function openCheckTelKiadas(destId) {var actDate = new Date();ctkAjaxPopupRunFunctionOnEnd('/ctk/kredit/telKiadas.jsp?timeForNoCache=' + actDate.valueOf() + '&destId=' + destId, 'Telefonszám kiadás', '850', '460');}var titleBarHeight = 35;function minimizePage() {  // Get paragraph height  var paragraph =  document.getElementById('mainDivOfPage');   var paragraphHeight = paragraph.offsetHeight;  var jmyAlertMsgs = jQuery("#myAlert-messages");  var jPopup = jmyAlertMsgs.find(".popup:last");   var newWindowFullHeight = paragraphHeight + titleBarHeight;  // Set paragraph area on pagejPopup.css({height: newWindowFullHeight + "px"});}function centerDivOnPopup(id) {  // Get paragraph heightvar paragraph =  document.getElementById(id); var paragraphHeight = paragraph.offsetHeight;var jmyAlertMsgs = jQuery("#myAlert-messages");var jPopup = jmyAlertMsgs.find(".popup:last");var popupHeight = jPopup.height();paragraph.style.paddingTop = (popupHeight - paragraphHeight - titleBarHeight) / 2 + "px";}function trim(str) {return str.replace(/^\s\s*/, '').replace(/\s\s*$/, '');}function popupKuldjSmst(destId) {var actDate = new Date();ajaxPopup('/ctk/kuldjSmst.jsp?timeForNoCache=' + actDate.valueOf() + '&destId=' + destId, 'Sms küldés', '800', '250', '');}function simplePreload() {  var args = simplePreload.arguments;  document.imageArray = new Array(args.length);  for(var i=0; i<args.length; i++) {    document.imageArray[i] = new Image;    document.imageArray[i].src = args[i];  }}function popup(theURL,winName,width,height,features) {  var window_width = width;  var window_height = height;  var newfeatures= features;  var window_top = (screen.height-window_height)/2;  var window_left = (screen.width-window_width)/2;  newWindow=window.open(''+ theURL + '',''+ winName + '','width=' + window_width + ',height=' + window_height + ',top=' + window_top + ',left=' + window_left + ',features=' + newfeatures + '');  newWindow.focus();}function submitVelemeny(form, comment, userId, votes, score) {  var value = new String(comment);  for (i=0;i<value.length;i++) {    value = value.replace("\u0150",";0150");    value = value.replace("\u0151",";0151");    value = value.replace("\u0170",";0170");    value = value.replace("\u0171",";0171");    value = value.replace("?", ";kdjel;");    value = value.replace("=", ";egn;");    value = value.replace("&", ";at;");    value = value.replace("/", ";per;");    value = value.replace("\\", ";back;");  }  //value = escape(value);  //myAlert('update' + value);  AjaxUtil.update(form + value, '', {onComplete: function(){    openDetailPersonalForm('velemeny', userId);    var elem1=document.getElementById('votes');    var elem2=document.getElementById('averagevotes');    if (elem1) {      elem1.innerHTML=votes;    }    if (elem2) {    	updateAverageVote(elem2, votes, score);    }    //myAlert("Szavazás megtörtént!");    return false; }});  return false;}function submitVelemeny2(form, comment, userId, votes, score) {  var value = new String(comment);  for (i=0;i<value.length;i++) {    value = value.replace("\u0150",";0150");    value = value.replace("\u0151",";0151");    value = value.replace("\u0170",";0170");    value = value.replace("\u0171",";0171");    value = value.replace("?", ";kdjel;");    value = value.replace("=", ";egn;");    value = value.replace("&", ";at;");    value = value.replace("/", ";per;");    value = value.replace("\\", ";back;");  }  AjaxUtil.update(form + value, "szavazzRamValtozoReszDivId", {onComplete: function(){    myAlert("Szavazás megtörtént!");    return false; }  });  return false;}function updatePageToDiv(url, divId) {  AjaxUtil.update(url, divId, {onComplete: function(){}  });  return false;}function setSubAdatlapPageActive(userExtId, subPage, extraParam) {if (extraParam == null) {extraParam = '';}updatePageToDiv('/ctk/adatlap/' + subPage + '.jsp?userExtId=' + userExtId + extraParam, 'jobboldalDiv');}function updateAverageVote(elem, vote, score){var list = document.getElementById('piOpinionID');var index = list.selectedIndex;var text = list.options[index].innerHTML;var begin = text.indexOf("(");var end = text.indexOf(" ", begin);var choosed = parseInt(text.substring(begin+1, end));var sum = parseInt(score)+choosed;var avg = (sum)/vote;document.getElementById('votesum').innerHTML=sum;elem.innerHTML=avg.toPrecision(3);}function submitJegyzeteles(form) {  AjaxUtil.submit(form, "actionFrame");  var elem1=document.getElementById('ivnotesaved');  if (elem1) {    elem1.innerHTML='Jegyzet elmentve';  }  return false;}function ctkAjaxSubmitFormAndColsePopupOnEnd(form){var progress = Liferay.Popup({width: 130,height: 100});AjaxUtil.submit(form, {onComplete: function(d){closePopup();}});return false;}function checkIVJelszo(form, mode){  var params = jQuery("input", form).serialize();  jQuery.ajax({        type: "POST",        url: "/ctk/adatlap/ivpwcheck.jsp",        data: params,        dataType: "xml",        success: function(xml){          var valid = jQuery(xml).find("success").attr("value");          if(valid == 1) {        	  AjaxUtil.update('/ctk/adatlap/telefonszamokKiadas.jsp', 'telefonszamokKiadasokDivId', {        		    onComplete: function(){        		  		closePopup();        		    }        		  });        	            } else {              var elem1 = jQuery('#ivjelszo');              elem1.html('Helytelen jelszo');          }        },        error: function(xml, stat, thr){          myAlert("Error occured while retrieving data from server:\n>>> "+stat);        }  })}function myAlert(theMessage) {while(theMessage.indexOf("\n")>-1){theMessage = theMessage.replace("\n", "<br>");}var popup = Liferay.Popup({title: '',modal: true,width: '800',height: '800',noCenter: true});var oldmyAlertDiv = jQuery("#mymyAlertPopupMessageId");if (oldmyAlertDiv.size() == 0) {jQuery("body").append("<div id='mymyAlertPopupMessageId' style='display:none'>" + theMessage + "</div> ");oldmyAlertDiv = jQuery("#mymyAlertPopupMessageId");} else {oldmyAlertDiv.html(theMessage);}AjaxUtil.update('/ctk/myAlert.jsp', popup, {onComplete: function() {jQuery("#themyAlertDivId").html(oldmyAlertDiv.html());Liferay.Popup.center();}});}function submitIVJelszo(form, jelszo, userId, userExtId, phone, phoneNumber, mode) {//	AjaxUtil.submit(form, "actionFrame");  if (form.ivpassword.value!=jelszo) {    var elem1=document.getElementById('ivjelszo');    if (elem1) {      elem1.innerHTML='Helytelen jelszo';	//	HA EKEZETEK VANNAK EBBEN A SORBAN, IE6-BAN ELSZALL    }    return false;  }  AjaxUtil.submit(form, {onComplete: function(){    Liferay.Popup.close(form);  }});  if (mode==0) {    //Liferay.Popup.close(window);  }  if (mode==1) {    location.href="/registration/view?uid=" +userId;  }  if (mode==2) {    //window.open('/nyomtatas/adatlap?userId='+userExtId);    popup('/nyomtatas/adatlap?userId='+userExtId, 'Adatlap', 600, 800, 'resizable=1,scrollbars=1');  }    var telefonszam=document.getElementById('telefonszam');    var telefonszam2=document.getElementById('telefonszam_2');    if (phone=="getIVPassword_always" || phone=="getIVPassword_once") {      if (telefonszam) {        telefonszam.innerHTML=phoneNumber;      }      if (telefonszam2) {        telefonszam2.innerHTML=phoneNumber;      }    }    var nyomtatas=document.getElementById('adatlap_nyomtatas');    if (nyomtatas) {//			nyomtatas.innerHTML='<a href="javascript:window.open(\'/nyomtatas/adatlap?userId='+userExtId+'\')">Adatlap nyomtat&aacute;sa</a>';      nyomtatas.innerHTML='<a href="javascript:popup(\'/nyomtatas/adatlap?userId='+userExtId+'\', \'Adatlap\', 600, 800, \'resizable=1,scrollbars=1\')">Adatlap nyomtat&aacute;sa</a>';    }    var modositas=document.getElementById('adatlap_modositas');    if (modositas) {      modositas.innerHTML='<a href="/registration/view?uid='+userId+'">Adatlap m&oacute;dos&iacute;t&aacute;sa</a>';    }  return false;}function replaceAll( str, replacements ) {  for ( i = 0; i < replacements.length; i++ ) {    var idx = str.indexOf( replacements[i][0] );    while ( idx > -1 ) {      str = str.replace( replacements[i][0], replacements[i][1] );      idx = str.indexOf( replacements[i][0] );    }  }  return str;}function deleteTableRow(elem){  var row = jQuery(elem).parents("tr:last").remove();}function deleteSearchTableRow(elem){  var row = jQuery(elem).parents(".searchRow:last").remove();}function validateUser(user, elem){  url = "/registration/validate/do?u="+user;  AjaxUtil.update(url, '', {    onComplete: function(){      deleteTableRow(elem);    }  });}function validateUser2(user, elem){myConfirm("Biztosan végrehajtod a jóváhagyást?", function() {url = "/registration/validate/do?u=" + user;AjaxUtil.update(url, '', {onComplete: function(){location.href = location; }});});}function validateUser3(user, elem,backURL){  url = "/registration/validate/do?u="+user;  AjaxUtil.update(url, '', {    onComplete: function(){     	location.href=backURL;    }  });}function modifyRequest(user, cid){  url = "/registration/validate/request?u="+user;  AjaxUtil.update(url, '', {    onComplete: function(){     myAlert("Levél elküldve a küls\u0151 címre!");    }  });  //newMailTo(cid);}function submitOfficeFilter(form){  var popup = Liferay.Popup({    width: 130,    height: 80  });  var url = "/ctk/registration/office/table.jsp";  var inputs = jQuery("input[@checked], select", form);  var params = inputs.serialize()  if(params.length > 0){    url = url+"?"+params;  }  AjaxUtil.update(url, 'irodaTable', {    onComplete: function(){      Liferay.Popup.close(popup);    }  });  return false;}function enableSex(){  jQuery("#sex").attr("disabled", false);}function showAppropriateBalAlsoDiv(actDiv) {if (actDiv == 'sargalap') {// aktiv class levesszuk mert jobb oldlara toltjuk be a sargalapotvar aktivObj = jQuery(".aktiv");aktivObj.removeClass("aktiv");aktivObj.addClass("link");aktivObj.find("a").addClass("simple_red");      		   } else {jQuery("[@showableBalAlso='showableBalAlso']").each(    function(p) {      jQuery(this).hide();    }  );jQuery("#" + actDiv).show();}}function checkCreditsSumma(form){  var summa = parseInt(jQuery("#user_credits").val());  jQuery("input[@type=checkbox][@money=money][@checked]:not(:disabled)",form).each  (    function(p)    {      var cbName = jQuery(this).attr("name");      var price = parseInt(jQuery("#price_" + cbName).val());      if ("vip_szektor" == cbName)      {        price *= parseInt(jQuery("#vipunit").val());        if (summa-price < 0)        {        	price = parseInt(jQuery("#price_" + cbName).val());        	jQuery("#vipunit").val(1);        }      }      summa -= price;    }  );  jQuery("#user_credits_txt").text(summa);  jQuery("input[@money=money][@type=checkbox]:not(:checked)",form).each  (    function(p)    {      var cbName = jQuery(this).attr("name");      jQuery(this).attr("disabled", summa < parseInt(jQuery("#price_" + cbName).val()));      if ("vip_szektor" == cbName)      {        jQuery("#vipunit").attr("disabled", summa < parseInt(jQuery("#price_" + cbName).val()));      }    }  )}function setPacketData(premiumRadio, form){  var isPremium = jQuery("#group_8").attr("checked") != undefined;  var termins = jQuery("input[@type=radio][@name=termin]");  jQuery("input[@type=radio][@name=group]").each  (    function(p)    {      //myAlert(jQuery(this).attr("checked"));      if (jQuery(this).attr("checked") == true)      {        var groupValue = jQuery(this).attr("value");        termins.each        (          function(pp)          {            var terminValue = jQuery(this).attr("value");            jQuery("#price_"+ terminValue).text(packets[""+groupValue+"_"+terminValue]["price"]);            jQuery("#credit_"+ terminValue).text(packets[""+groupValue+"_"+terminValue]["credit"]);          }        )      }    }  );  termins.each  (    function(p)    {      jQuery(this).attr("disabled",12 != jQuery(this).val() && isPremium);      if (isPremium && 12 == jQuery(this).val())      {        jQuery(this).attr("checked", true);      }      else if (3 == jQuery(this).val())      {        jQuery(this).attr("checked", true);      }    }  );}function toggleFullArticle(){if ( document.getElementById("fullarticle").style.visibility == "hidden" ){document.getElementById("fullarticle").style.visibility = "visible";}else{document.getElementById("fullarticle").style.visibility = "hidden";}}function openCheckRight(funcName, callFunc, w, h){  var popup = Liferay.Popup({    title: '',    modal: true,    width: w,    height: h,    noCenter: true  });  AjaxUtil.update('/ctk/kredit/checkcredits.jsp?funcName=' + funcName, popup,  {    onComplete: function()    {      var jmyAlertMsgs = jQuery("#myAlert-messages");      var jPopup = jmyAlertMsgs.find(".popup:last");      var el = jQuery(".popup-message:last");      var success = jQuery('#success');            if(success.val() == 1) {          var element = jQuery('.popup-close:last');          eval(callFunc);          Liferay.Popup.close(element);    	        } else {        jPopup.css({              width: 500 + "px",              height: (jQuery("#errorl").val() / 90) * 25 + 50 + "px"            });            el.css({              width: 500 + "px",              height: (jQuery("#errorl").val() / 90) * 25 + 50 + "px"            });        Liferay.Popup.center();      }    }});}function openCheckRight2(funcName, userExtId, subPage, extraParam, forced) {if (forced == true) {setSubAdatlapPageActive(userExtId, subPage, extraParam);} else {  AjaxUtil.update('/ctk/kredit/checkcredits.jsp?funcName=' + funcName, 'errorMessageDivId',  {    onComplete: function()    {      var success = jQuery('#success');      if(success.val() == 1)      {         setSubAdatlapPageActive(userExtId, subPage, extraParam);      }      else {    	  var popup = Liferay.Popup({  		    title: '',  		    modal: true,  		    width: '400',  		    height: '400',  		    noCenter: true  		  });    	      	  var errorString = jQuery("#checkKreditsDivId");    	  AjaxUtil.update('/ctk/emptyPage.jsp?', popup,  {    		  onComplete: function()    		  {    		  	  var emptyDiv = jQuery("#emptyPageDivId");    		  	  emptyDiv.html(errorString.html());          Liferay.Popup.center();    		  }  });      }    }});}}function openCheckRight3(funcName, subPage, callFunc){  AjaxUtil.update('/ctk/kredit/checkcredits.jsp?funcName=' + funcName, 'errorMessageDivId',  {    onComplete: function()    {      var success = jQuery('#success');      if(success.val() == 1)      {    	  showAppropriateBalAlsoDiv(subPage);    	  if (callFunc != null) {    		  eval(callFunc);    	  }      }      else {    	  var popup = Liferay.Popup({  		    title: '',  		    modal: true,  		    width: '400',  		    height: '400',  		    noCenter: true  		  });    	      	  var errorString = jQuery("#checkKreditsDivId");    	  AjaxUtil.update('/ctk/emptyPage.jsp?', popup,  {    		  onComplete: function()    		  {    		  	  var emptyDiv = jQuery("#emptyPageDivId");    		  	  emptyDiv.html(errorString.html());          Liferay.Popup.center();    		  }  });      }    }});}function openCheckRight4(funcName, callFunc){  AjaxUtil.update('/ctk/kredit/checkcredits.jsp?funcName=' + funcName, 'errorMessageDivId',  {    onComplete: function()    {      var success = jQuery('#success');      if(success.val() == 1)      {    	  if (callFunc != null) {    		  eval(callFunc);    	  }      }      else {    	  var popup = Liferay.Popup({  		    title: '',  		    modal: true,  		    width: '400',  		    height: '400',  		    noCenter: true  		  });    	      	  var errorString = jQuery("#checkKreditsDivId");    	  AjaxUtil.update('/ctk/emptyPage.jsp?', popup,  {    		  onComplete: function()    		  {    		  	  var emptyDiv = jQuery("#emptyPageDivId");    		  	  emptyDiv.html(errorString.html());          Liferay.Popup.center();    		  }  });      }    }});}function showGoogleMaps(title, opid) {var url = '/ctk/search/showOfficeGoogleMaps.jsp';if (opid != null) {url += '?googleOfficePartnerId=' + opid;}ajaxPopup(url, title, '600', '600', '');}function showError(key){  var popup = Liferay.Popup({    title: '',    modal: true,    width: 500,    height: 600,    noCenter: true  });  	  AjaxUtil.update('/ctk/search/showError.jsp?key=' + key, popup,  {    onComplete: function()    {        Liferay.Popup.center();    }});}function openBuyCreditPopup(key){  var popup = Liferay.Popup({    title: '',    modal: false,    width: 500,    height: 50,    noCenter: true  });  AjaxUtil.update('/ctk/kredit/buycredits.jsp?key=' + key, popup,  {    onComplete: function()    {      var jmyAlertMsgs = jQuery("#myAlert-messages");      var jPopup = jmyAlertMsgs.find(".popup:last");      var el = jQuery(".popup-message:last");      var success = jQuery('#success');      if(success.val() == 0)      {        jPopup.css({              width: 500 + "px",              height: (jQuery("#errorl").val() / 90) * 25 + 50 + "px"            });            el.css({              width: 500 + "px",              height: (jQuery("#errorl").val() / 90) * 25 + 50 + "px"            });        Liferay.Popup.center();      }      else      {        var element = jQuery('.popup-close:last');        eval(callFunc);        Liferay.Popup.close(element);      }    }});    return false;}function updateMessageStatus(messageId, status){  url = "/ctk/levelezes/setMesssageStatus.jsp?m="+messageId + "&s="+status;  AjaxUtil.update(url, 'statusCell_'+messageId, {    onComplete: function(){ }  });}function updateMessageStatusAskPhone(messageId, status){  url = "/ctk/levelezes/setMesssageStatusAskPhone.jsp?m="+messageId + "&s="+status;  AjaxUtil.update(url, 'statusCell_'+messageId, {    onComplete: function(){ }  });}function ctkSubmitForm(form, container){AjaxUtil.submit(form, {update: container, disable: true,onComplete: function(){var inputs = jQuery("input, textarea, select", form);inputs.attr("disabled", false);}});}function loadFizetesiModokCore2(packetType, termination, marStandard, errorMsg, classicotAkar) {if (marStandard == true) {if (classicotAkar == false) {// mar standard es standaerdre kattintmyAlert(errorMsg);} else {// vanmar Standard de Classicot akarmyConfirm(errorMsg, function() {loadFizetesiModokCore2Real(packetType, termination);});}} else {// nincs meg standardja semmilyen csomagja (classis sem, premiumnal meg ez nem jelenhet meg)loadFizetesiModokCore2Real(packetType, termination);}}function loadFizetesiModokCore2Real(packetType, termination) {closePopup();setTimeout("loadFizetesiModokCoreReal2('" + packetType + "','" + termination + "');", 500);}function loadFizetesiModokCoreReal2(packetType, termination) {var popup = Liferay.Popup({title: '',modal: true,width: 700,height: 700,noCenter: false,disableCloseWindow: false,kulsoDivId: 'layer_window'});var urln = '/ctk/kredit/fizetesiModValasztas.jsp?packetType=' + packetType + '&termination=' + termination;AjaxUtil.update(urln, popup, {onComplete: function(){Liferay.Popup.center();}});}function loadHonapValasztoVissza() {closePopup();setTimeout('loadHonapValaszto()', 500);}function loadHonapValaszto() {var popup = Liferay.Popup({title: '',modal: true,width: 700,height: 700,noCenter: false,disableCloseWindow: false,kulsoDivId: 'layer_window'});var urln = '/ctk/kredit/honapValasztas.jsp?';AjaxUtil.update(urln, popup, {onComplete: function(){Liferay.Popup.center();}});}function loadFizetesiModokCore(packetType) {closePopup();setTimeout("loadFizetesiModokCoreReal('" + packetType + "');", 500);}function loadFizetesiModokCoreReal(packetType) {var popup = Liferay.Popup({title: '',modal: true,width: 700,height: 700,noCenter: false,disableCloseWindow: false		});var urln = '/ctk/kredit/fizetesiModokPopup.jsp?&packetType=' + packetType;AjaxUtil.update(urln, popup, {onComplete: function(){Liferay.Popup.center();}});}function loadFizetesiModok(packetType, marStandard, standardVanMessage, isConfirm) {if (marStandard == true) {if (isConfirm == true) {myConfirm(standardVanMessage, function() {loadFizetesiModokCore(packetType, marStandard);});} else {// csak alertet rakunkmyAlert(standardVanMessage);}} else {loadFizetesiModokCore(packetType, marStandard);}}function loadFizetesVegsoPopup(paymentType, packetType) {closePopup();setTimeout("loadFizetesVegsoPopupTimeout('" + paymentType + "','" + packetType + "');", 500);}function loadFizetesVegsoPopupTimeout(paymentType, packetType) {var popup = Liferay.Popup({title: '',modal: true,width: 800,height: 600,noCenter: false,disableCloseWindow: false		});var urln = '/ctk/kredit/fizetesValasztasVegsoUj.jsp?paymentType=' + paymentType + '&packetType=' + packetType;AjaxUtil.update(urln, popup, {onComplete: function(){Liferay.Popup.center();}});}function loadFizetesVegsoPopup2(elofizPacket) {closePopup();setTimeout("loadFizetesVegsoPopupTimeout2('" + elofizPacket + "');", 500);}function loadFizetesVegsoPopupTimeout2(elofizPacket) {var popup = Liferay.Popup({title: '',modal: true,width: 800,height: 600,noCenter: false,disableCloseWindow: false,kulsoDivId: 'layer_window'});var urln = '/ctk/kredit/fizetesValasztasVegsoUj2.jsp?elofizPacket=' + elofizPacket;AjaxUtil.update(urln, popup, {onComplete: function(){Liferay.Popup.center();}});}function loadInfoFizetesrolPopup(paymentType, packetType) {var popup = Liferay.Popup({title: 'Tájékoztató',modal: true,width: 700,height: 380,noCenter: false,disableCloseWindow: false		});var urln = '/ctk/kredit/infoVasarlasrol.jsp?paymentType=' + paymentType + '&packetType=' + packetType;AjaxUtil.update(urln, popup, {onComplete: function(){minimizePage();Liferay.Popup.center();}});}function loadSelectedPayment(paymentType, packetType) {loadFizetesVegsoPopup(paymentType, packetType);}function disableAutomaticHosszabbitas(confirmText, enablity) {myConfirm(confirmText, function() {location.href="/onlineelofizetes?modify=Modify&autopay=" + enablity;});}function myConfirm(text, caseTrueFvn, caseFalseFvn, disableClosePopupAfterCaseTrue, disableClosePopupAfterCaseFalse) {var popup = Liferay.Popup({title: '',modal: true,width: 700,height: 700,noCenter: false,disableCloseWindow: false		});var urln = '/ctk/myConfirm.jsp';AjaxUtil.update(urln, popup, {onComplete: function(){jQuery("#theConfirmDivId").html(text);jQuery("#myModalYesButton").click(function() {if (caseTrueFvn != null) {caseTrueFvn();}if (disableClosePopupAfterCaseTrue == null) {closePopup();}});jQuery("#myModalNoButton").click(function() {if (caseFalseFvn != null) {caseFalseFvn();}if (disableClosePopupAfterCaseFalse == null) {closePopup();}});Liferay.Popup.center();}});}checkNumberFormat = function(elem){var value = replaceAll(elem.value,' ','');var fpos;var lchar = value.substr(value.length-1);if(lchar>-1 && lchar<10){elem.value = value;}else{fpos = value.indexOf(lchar);elem.value = value.substr(0,fpos);}}function loadSmsMoPopup(elofizPacket, autoPay, needBill, billFirstName, billLastName, billCity, billAddress, billZip, notifCity, notifAddress, notifZip) {var popup = Liferay.Popup({title: 'Vásárlás',modal: true,width: 700,height: 300,noCenter: false,disableCloseWindow: false,onBeforeClose: function() {myConfirm('Biztosan bezárod az ablakot?',function() { closePopup(); },null );return false;}});var urln = '/ctk/kredit/smsMo.jsp?elofizPacket=' + elofizPacket + '&autopay=' + autoPay + '&needBill=' + needBill + '&billFirstName=' + billFirstName + '&billLastName=' + billLastName + '&billCity=' + billCity + '&billAddress=' + billAddress + '&billZip=' + billZip + '&notifCity=' + notifCity + '&notifAddress=' + notifAddress + '&notifZip=' + notifZip;AjaxUtil.update(urln, popup, {onComplete: function(){jQuery("#moResult").hide();minimizePage();Liferay.Popup.center();jQuery("#azonosito").focus();}});}function loadSmsMoResult(chosenPaymenId) {var azonosito = jQuery("#azonosito").val();var phoneNum = jQuery("#phoneNumPre").val() + jQuery("#phoneNum").val();var urln = '/ctk/kredit/smsMo.jsp?elofizPacket=' + chosenPaymenId + '&azonosito=' + azonosito + '&phoneNum=' + phoneNum  + '&showResult=true';AjaxUtil.update(urln, "moResult", {onComplete: function(){jQuery("#azonosito").focus();var resultDiv = jQuery("#resultDiv");var str = resultDiv.text();var str = str.replace(/\'\'/g,"'");var str = str.replace(/\\n/g,"\n");myAlert(str);if (resultDiv.attr("closeWindow") == "true") {closePopup();}}});}function loadSmsMtPopup(elofizPacket, autoPay, needBill, billFirstName, billLastName, billCity, billAddress, billZip, notifCity, notifAddress, notifZip) {var popup = Liferay.Popup({title: 'Vásárlás',modal: true,width: 700,height: 300,noCenter: false,disableCloseWindow: false,onBeforeClose: function() {   return true;}});var urln = '/ctk/kredit/smsMt.jsp?elofizPacket=' + elofizPacket + '&autopay=' + autoPay + '&needBill=' + needBill + '&billFirstName=' + billFirstName + '&billLastName=' + billLastName + '&billCity=' + billCity + '&billAddress=' + billAddress + '&billZip=' + billZip + '&notifCity=' + notifCity + '&notifAddress=' + notifAddress + '&notifZip=' + notifZip;AjaxUtil.update(urln, popup, {onComplete: function(){minimizePage();Liferay.Popup.center();}});}function closePopup() {var popupAct = jQuery(".popup-message:last");    Liferay.Popup.close(popupAct);}function pageTable(tableURL, page, container, params){var url = tableURL+"?cp="+page;url += params;showProgress(url, container);}function setRows(tableURL, container_, selector, params){var rows = 20;var url = tableURL;if(selector){url+="?rows="+selector.value;if (params) {url += params;}}showProgress(url, container_);}function checkCoordinates(){regexp = /^[0-9]+°[0-9]+'[0-9]+.[0-9]+$/;var cy = jQuery('#officeY');var cx = jQuery('#officeX');if(!regexp.test(cy.val())){cy.addClass('redBkg');} else{cy.removeClass('redBkg');}if(!regexp.test(cx.val())){cx.addClass('redBkg');} else{cx.removeClass('redBkg');}}function checkData(){var error = "";if (document.getElementById("needBill").checked){     var billFirstName = jQuery("#billFirstName").val();    var billLastName = jQuery("#billLastName").val();    var billAddress = jQuery("#billAddress").val();    var billCity = jQuery("#billCity").val();    var billZip = jQuery("#billZip").val();    var notifAddress = jQuery("#notifAddress").val();    var notifCity = jQuery("#notifCity").val();    var notifZip = jQuery("#notifZip").val();        if ("" == notifAddress) { error = "Számla kérés esetén a levelezési címnél az utca/házszám kitöltése kötelez\u0151!\n"; }	        if ("" == notifZip) { error = "Számla kérés esetén a levelezési címnél az irányítószám kitöltése kötelez\u0151!\n"; } if ("" == notifCity) { error = "Számla kérés esetén a levelezési címnél a város kitöltése kötelez\u0151!\n"; } if ("" == billAddress) { error = "Számla kérés esetén a számlázási címnél az utca/házszám kitöltése kötelez\u0151!\n"; } if ("" == billZip) { error = "Számla kérés esetén a számlázási címnél az irányítószám kitöltése kötelez\u0151!\n"; } if ("" == billCity) { error = "Számla kérés esetén a számlázási címnél a város kitöltése kötelez\u0151!\n"; }  if ("" == billLastName) { error = "Számla kérésnél a keresztnév kitöltése kötelez\u0151!\n"; }  if ("" == billFirstName) { 	error = "Számla kérésnél a vezetéknév kitöltése kötelez\u0151!\n"; }     }if (!document.getElementById("paycond").checked == true){ 	error = "A fizet\u00e9si felt\u00e9telek elfogad\u00e1sa k\u00f6telez\u0151!\n";}if ("" != error){myAlert(error);return false;}return true;}function setPaymentType(field,type){Liferay.Popup.close(field);if (checkPaymentForm()){form = jQuery("#paymentForm");if ("mobilshop" == type){form.action = "/ctk/kredit/shoppingredirect.jsp";}else if ("sms" == type){form.action = "/ctk/kredit/shoppingredirect.jsp";}else if ("online" == type){form.action = "/ctk/kredit/shoppingredirect.jsp";};form.submit();}}function showImageUrl(imageName, title, width, height) {ajaxPopup('/ctk/showOnlyImageUrl.jsp?imgUrl=' + imageName, title, width, height, '');}function showBillPanel() {if (document.getElementById("needBill").checked == true) {jQuery('#billPanel').show();} else {jQuery('#billPanel').hide();//		minimizePage();}}function showDataModifications(uid, title) {ctkAjaxPopup('/ctk/registration/viewModificationsByUer.jsp?uid=' + uid, title, '800', '600');}function changeShow(id) {var elementShow = jQuery("#" + id);if (elementShow.is(":visible") == false) {elementShow.show();elementShow.attr("myVisible", "true");} else {elementShow.hide();elementShow.attr("myVisible", "false");}}function showCsomagTablazat() {ajaxPopup('/ctk/kredit/artablazat_elofizUj.jsp', '', '1024', '550', '');}function showGarancia() {ajaxPopup('/ctk/static/jsp/other/garanciaPopup.jsp', '', '970', '600', '');}function showNotHasRole(messageCode) {ajaxPopup('/ctk/search/showNotHaveRole.jsp?messageCode='+messageCode, '', '1024', '550', '');}function showCsomagTablazatTimeout() {setTimeout('showCsomagTablazat()', 0);}function showTarskeresesReszletesOnline() {ajaxPopup('/ctk/static/jsp/onlineTarskeresesPopup.jsp', '', '800', '600', '');}function showTarskeresesReszletesKlasszikus() {ajaxPopup('/ctk/static/jsp/klasszikusTarskeresesPopup.jsp', '', '800', '600', '');}Calendar._DN = new Array("Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday","Sunday");Calendar._SDN = new Array("Sun","Mon","Tue","Wed","Thu","Fri","Sat","Sun");Calendar._MN = new Array("January","February","March","April","May","June","July","August","September","October","November","December");Calendar._SMN = new Array("Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec");Calendar._TT = {};Calendar._TT["ABOUT"] = "Use the \xab and \xbb buttons to select the year. Use the {0} and {1} buttons to select the month. Hold the mouse button on any of the above buttons for faster selection.";Calendar._TT["ABOUT"] = Calendar._TT["ABOUT"].replace("{0}", String.fromCharCode(0x2039));Calendar._TT["ABOUT"] = Calendar._TT["ABOUT"].replace("{1}", String.fromCharCode(0x203a));Calendar._TT["ABOUT_TIME"] = "";Calendar._TT["CLOSE"] = "Close";Calendar._TT["DAY_FIRST"] = "Display %s First";Calendar._TT["DRAG_TO_MOVE"] = "";Calendar._TT["GO_TODAY"] = "Today";Calendar._TT["INFO"] = "Help";Calendar._TT["NEXT_MONTH"] = "Next Month";Calendar._TT["NEXT_YEAR"] = "Next Year";Calendar._TT["PART_TODAY"] = "";Calendar._TT["PREV_MONTH"] = "Previous Month";Calendar._TT["PREV_YEAR"] = "Previous Year";Calendar._TT["SEL_DATE"] = "Select Date";Calendar._TT["SUN_FIRST"] = "";Calendar._TT["TIME_PART"] = "";Calendar._TT["TODAY"] = "Today";Calendar._TT["WK"] = "";Calendar._TT["DEF_DATE_FORMAT"] = "%Y-%m-%d";Calendar._TT["TT_DATE_FORMAT"] = "%a, %b %e";Calendar._TT["WEEKEND"] = "0,6";