2012-11-22 2 views
0

좋습니다. 가능하면 두 개의 로그인 양식이있는 단일 페이지가 있습니다. 그러나 동일한 사용자 이름과 암호를 사용합니다. 한 번 내가 하나의 양식에 로그인하면 내 사용자 이름이 이미 내 사용자 이름을 가지고 있으며 암호는 데이터베이스에서 가져옵니다.양식 입력 필드 끌어 오기 또는 자동 채우기

<form action="home.php" method="post" id="LoginForm" style="color:#FFF"> 
<input type="hidden" name="SessionID" value="new"></input> 
Username: 
<input type="text" name="AccountNo" value="" class="input" size="28"></input> 
<BR /><BR /> 
&nbsp;&nbsp;Password: 
<input type="password" name="Password" value="" class="input" size="30"></input> 
<BR /> 
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<input type="image" src="images/input-img.gif" value="Log On" class="input-img"></input> 
<BR /><br /> 
<a href="#" class="link" style="font-size:12px;">Register now!</a> <a href="#" style="font-size:12px;">Forgotten your password?</a> 
</form> 

답변

0

질문이 가능한 경우 대답이 가능합니다.

양식을 제출하면 JavaScript를 사용하여 첫 번째 양식에서 사용자 이름을 읽고 두 번째 양식으로 채울 수 있습니다. 암호를 얻으려면 AJAX를 사용할 수 있습니다.

+0

좋아,이 작품이 좋아할까요? –

+0

+0

관련 문제