// Get base url var sitename = "http://www.regizz.hu/"; function sso_ajax_do (url) { // Does URL begin with http? if ((url.substring(0, 4) != 'http') && (url.substring(0, 1) != '/')) { url = sitename + "/" + url; } url += "&sso_user=puruttya.hu"; // Create new JS element var jsel = document.createElement('SCRIPT'); jsel.type = 'text/javascript'; jsel.src = url; // Append JS element (therefore executing the 'AJAX' call) document.body.appendChild (jsel); return true; } function sso_reg() { document.reg.regbutton.disabled = true; sso_ajax_do("reg.php?" + "email="+encodeURIComponent(document.reg.email.value)+"&"+ "password1="+encodeURIComponent(document.reg.password1.value)+"&"+ "password2="+encodeURIComponent(document.reg.password2.value)+"&"+ "capcha="+encodeURIComponent(document.reg.capcha.value) ); } function sso_chpw() { document.chpw.chpwbutton.disabled = true; sso_ajax_do("chpw.php?" + "password1="+encodeURIComponent(document.chpw.password1.value)+"&"+ "password2="+encodeURIComponent(document.chpw.password2.value) ); } function addLoadEvent(func) { var oldonload = window.onload; if(typeof window.onload != "function") window.onload = func; else window.onload = function() { oldonload(); func(); } } addLoadEvent(ssoOnLoad); function ssoOnLoad(){ var subframe = document.createElement('iframe'); subframe.style.display="none"; subframe.style.width="0px"; subframe.style.height="0px"; document.body.appendChild(subframe); subframe.src = sitename + "i4.php?sso_user=puruttya.hu&sso_uid=&sso_redirect=http%3A%2F%2Fblog.puruttya.hu%2Findex.php&sso_domain="; }