日期:2014-05-17 浏览次数:20725 次
<!--修改密码弹出层--> <div id="boxcontent" style="display: none"> <form id="amend" action="login!mm_update.action" method="post" onsubmit="return on_submit();"> <table class="from" border="0" cellspacing="1" cellpadding="0"> <tr> <th> 原密码: </th> <td> <input id="mm" name="yhs.mm" type="password" class="TextBox" /><font color="red">*</font> <input value="${yhs.id}" name="id" type="hidden"/> <input id="omm" value="${yhs.mm}" name="mm" type="hidden"/> </td> </tr> <tr> <th> 新密码: </th> <td> <input id="new_mm" name="new_mm" type="password" class="TextBox" /> </td> </tr> <tr> <th> 确认新密码: </th> <td> <input id="con_mm" name="con_mm" type="password" class="TextBox" /> </td> </tr> </table> <input type="submit" value="修改" class="button" style="margin-top: 10px; margin-left: 80px; margin-bottom: 10px" /> <input type="button" value="取消" onclick="cancel(0);" class="dialog-cancel" style="margin-top: 10px; margin-bottom: 10px" /> <script type="text/javascript"> //密码修改验证 function on_submit() { var value=$("#omm").val(); var value2=$("#mm").val(); if(value!=value2){ alert("原始密码不正确"); amend.mm.focus(); return false; } if(amend.new_mm.value==""){ alert("新密码不能为空"); amend.new_mm.focus(); return false; } if(amend.con_mm.value==""){ alert("请在依次输入密码"); amend.con_mm.focus(); return false; } if(amend.con_mm.value!==amend.new_mm.value){ alert("两次密码不一致,请重新输入"); amend.con_mm.focus(); return false; } } </script> </form> </div>