var enabled="";
var exp = new Date(); 
exp.setTime(exp.getTime() + (10*60*1000));


function checkit(password_rowe) {
var protect = password_rowe 
if (document.bejelentkez_rowe.passwort_rowe.value=="") {
  alert("Kérem, adja meg jelszavát!"); }
else {
SetCookie ('passed', 1, exp);

newWindow = window.open('','newWin','width=750,height=500,top=30,left=30,toolbar=yes,location=no,directories=no,status=no,scrollbars=yes,resizable=yes,copyhistory=no');
newWindow.document.location.href = protect + "/index.html"; }
}


function checkit2(password_alk) {
var protect = password_alk
if (document.bejelentkez_alk.passwort_alk.value=="") {
  alert("Kérem, adja meg jelszavát!"); }
else {
SetCookie ('passed', 1, exp);

newWindow = window.open('','newWin','width=750,height=500,top=30,left=30,toolbar=yes,location=no,directories=no,status=no,scrollbars=yes,resizable=yes,copyhistory=no');
newWindow.document.location.href = "alkatresz/" + protect + "/index.html"; }
}


function SetCookie (name, value) 
 {
 var argv = SetCookie.arguments;
 var argc = SetCookie.arguments.length;
 var expires = (argc > 2) ? argv[2] : null;
 var path = (argc > 3) ? argv[3] : null;
 var domain = (argc > 4) ? argv[4] : null;
 var secure = (argc > 5) ? argv[5] : false;
 document.cookie = name + "=" + escape (value) +
 ((expires == null) ? "" : ("; expires=" + expires.toGMTString())) +
 ((path == null) ? "" : ("; path=" + path)) +
 ((domain == null) ? "" : ("; domain=" + domain)) +
 ((secure == true) ? "; secure" : "");
 }
