HTTP 로그인 인증창에 대해 질문합니다 도와주세요ㅠㅠ

· 13년 전 · 1011
안녕하세요
저는 로그인페이지를 만들었는데..어떤 고객의 요청으로 인해
로그인페이지보다 그냥 "HTTP 로그인 인증창"이 띄울수있도록 원하답니다.
그래서 고객의 요청대로 그렇게 만들었는데..잘 안되었어요 ㅠㅠ
▒▒▒▒▒ 로그인 페이지 ▒▒▒▒▒
<?
require "include/config.php";
include "include/index_cookie.php";

if($_SESSION[mb_userid]) { go_d(0,'m_sub01.html'); } // 이미 로그인 된경우 메인으로
?>
<meta http-equiv="Content-Type" content="text/html; charset=euc-kr">
<script language="JavaScript" src="<?echo"$HOME_PATH"?>/include/ebook.js"></script>
<LINK REL="StyleSheet" HREF="<?echo"$HOME_PATH"?>/include/style.css" type="text/css">
<link href="../include/style.css" rel="stylesheet" type="text/css">

<form action="app_login_act.html" method=post name=ebook_login onsubmit='return valid_ebooklogin_check()'>
<input type='hidden' name='mode' value='ebook_login'>
<?
if($_SERVER[HTTP_REFERER]) {
$returl = $_SERVER[HTTP_REFERER];
}else if($returl) {
$returl = $returl;
}
echo"<input type=hidden name=url value='$returl'>";
// echo"<input type=hidden name=url value='$PHP_SELF'>";
?>
<table width=80% border=0 align=center cellpadding="0" cellspacing="0">
<tr>
<td height="25" colspan=2 align=center>
로그인
<tr>
<td width="35%" height="25">로그인
<td width="65%" height="25"><input name="mb_userid" type="text" id="mb_userid" size="20">
<tr>
<td width="35%" height="25">비밀번호
<td width="65%" height="25"><input name="mb_pwd" type="password" id="mb_pwd" size="20" onKeyPress="if(window.event.keyCode==13) ebooklogin();">
<tr>
<td height="25" colspan=2>
<input type="checkbox" onClick="id_save_delete(document.ebook_login);" name="id_save">자동로그인
<tr>
<td height="25" colspan=2 align=center>
<input type="submit" value="로그인" onclick="javascript:ebooklogin()">
</td>
</tr>
</table>
</form>
▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒
으로 잘 되었지만..
▒▒▒▒▒ HTTP 로그인 인증창 ▒▒▒▒▒
<?
require "include/config.php";
include "include/index_cookie.php";

if($_SESSION[mb_userid]) { go_d(0,'m_sub01.html'); } // 이미 로그인 된경우 메인으로
function authenticate() // 인증을 받기 위해 인증 창을 여는 함수!
{
// 인증 창이 떴을때의 문구와 인증 창의 헤더 설정!
Header( "WWW-authenticate: basic realm=\"ADMIN영역\" ");
Header( "HTTP/1.0 401 Unauthorized");

// 아이디와 비밀번호가 일치하지 않을때 보여주는 문구!
echo("이곳에 들어오시려면 관리자 아이디 암호가 필요합니다.");
exit;
}
// 관리자 정보가 없을때 인증 창을 불러내는 부분으로서 관리자 인증을 받을때까지 인증 창을 띄움.
if(!isset($_SESSION[mb_userid]) || ($PHP_AUTH_USER!='mb_userid' || $PHP_AUTH_PW!='mb_pwd')) {
authenticate();
}
?>
▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒
수정해봤는데.. 잘 안되었습니다 ㅠㅠㅠ
도와주세요 ㅠㅠㅠ
|
댓글을 작성하시려면 로그인이 필요합니다.

프로그램

+
제목 글쓴이 날짜 조회
13년 전 조회 976
13년 전 조회 4,801
13년 전 조회 1,101
13년 전 조회 620
13년 전 조회 783
13년 전 조회 620
13년 전 조회 504
13년 전 조회 755
13년 전 조회 892
13년 전 조회 557
13년 전 조회 640
13년 전 조회 1,077
13년 전 조회 7,621
13년 전 조회 2,814
13년 전 조회 547
13년 전 조회 1,124
13년 전 조회 1,064
13년 전 조회 1,158
13년 전 조회 5,066
13년 전 조회 502
13년 전 조회 1,028
13년 전 조회 2,464
13년 전 조회 2,100
13년 전 조회 1,776
13년 전 조회 1,955
13년 전 조회 2,847
13년 전 조회 517
13년 전 조회 1,996
13년 전 조회 1,392
13년 전 조회 3,181
13년 전 조회 3,247
13년 전 조회 1,037
13년 전 조회 4,088
13년 전 조회 1,143
13년 전 조회 1,342
13년 전 조회 1,787
13년 전 조회 1,718
13년 전 조회 805
13년 전 조회 991
13년 전 조회 2,887
13년 전 조회 964
13년 전 조회 1,486
13년 전 조회 2,252
13년 전 조회 2,076
13년 전 조회 804
13년 전 조회 1,431
13년 전 조회 3,787
13년 전 조회 1,059
13년 전 조회 1,509
13년 전 조회 1,012
13년 전 조회 1,190
13년 전 조회 1,668
13년 전 조회 771
13년 전 조회 1,678
13년 전 조회 1,322
13년 전 조회 877
13년 전 조회 9,277
13년 전 조회 972
13년 전 조회 852
13년 전 조회 937
13년 전 조회 1,667
13년 전 조회 1,052
13년 전 조회 1,154
13년 전 조회 816
13년 전 조회 675
13년 전 조회 4,763
13년 전 조회 1,046
13년 전 조회 1,126
13년 전 조회 885
13년 전 조회 6,788
13년 전 조회 952
13년 전 조회 1,294
13년 전 조회 1,259
13년 전 조회 2,962
13년 전 조회 944
13년 전 조회 2,841
13년 전 조회 1,300
13년 전 조회 1,905
13년 전 조회 1,447
13년 전 조회 1,603
13년 전 조회 1,840
13년 전 조회 673
13년 전 조회 873
13년 전 조회 850
13년 전 조회 1,161
13년 전 조회 1,194
13년 전 조회 1,956
13년 전 조회 818
13년 전 조회 887
13년 전 조회 3,276
13년 전 조회 1,014
13년 전 조회 1,271
13년 전 조회 1,683
13년 전 조회 1,108
13년 전 조회 2,087
13년 전 조회 801
13년 전 조회 2,932
13년 전 조회 1,297
13년 전 조회 1,592
13년 전 조회 1,033
🐛 버그신고