📄 login.jsp
字号:
<%@ page language="java" import="java.util.*" pageEncoding="utf-8"%>
<%
String path = request.getContextPath();
String basePath = request.getScheme() + "://"
+ request.getServerName() + ":" + request.getServerPort()
+ path + "/";
%>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<html>
<title>用户登陆</title>
<head>
<base href="<%=basePath%>">
<title>My JSP 'MyJsp.jsp' starting page</title>
<meta http-equiv="pragma" content="no-cache">
<meta http-equiv="cache-control" content="no-cache">
<meta http-equiv="expires" content="0">
<meta http-equiv="keywords" content="keyword1,keyword2,keyword3">
<meta http-equiv="description" content="This is my page">
<script language="JavaScript" src="<%=basePath%>js/prototype.js"></script>
<script language="JavaScript" src="<%=basePath%>js/method.js"></script>
</head>
<style type="text/css">
body {
}
a:link {
color: #FF0000;
text-decoration: none
} /* 未访问的链接 */
a:visited {
color: #00FF00;
text-decoration: none
} /* 已访问的链接 */
a:hover {
color: #FF00FF;
text-decoration: underline
} /* 鼠标在链接上 */
a:active {
color: #0000FF;
text-decoration: underline
} /* 激活链接 */
body.menu {
background: #383757;
margin: 0px;
font-family: "Arial", "Helvetica", "sans-serif";
font-size: 8pt;
}
table.menu {
border: 0px;
font-family: "Arial", "Helvetica", "sans-serif";
font-size: 8pt;
}
td.menu {
font-family: "Arial", "Helvetica", "sans-serif";
font-size: 8pt;
}
img.menu {
vertical-align: bottom;
border: 0px;
}
a.menu {
font-family: "Arial", "Helvetica", "sans-serif";
font-size: 8pt;
color: #215DC6;
text-decoration: none;
TEXT-DECORATION: none;
}
a:hover .menu {
font-size: 8pt;
color: #428EFF;
font-family: "Arial", "Helvetica", "sans-serif";
color: #ff00ff
}
.sec_menu {
border-left: 1px solid gray;
border-right: 1px solid gray;
border-bottom: 1px solid gray;
overflow: hidden;
background: #f8f8f8;
}
.menu_title {
font-family: "Arial", "Helvetica", "sans-serif";
font-size: 8pt
}
.menu_title span {
position: relative;
top: 2px;
left: 8px;
color: #494949;
font-weight: bold;
font-family: "Arial", "Helvetica", "sans-serif";
font-size: 8pt
}
.menu_title2 {
font-family: "Arial", "Helvetica", "sans-serif";
font-size: 8pt
}
.menu_title2 span {
position: relative;
top: 2px;
left: 8px;
color: #428EFF;
font-weight: bold;
cursor: hand;
font-family: "Arial", "Helvetica", "sans-serif";
font-size: 8pt
}
</style>
<body background="images/4.jpg">
<table cellpadding=0 cellspacing=0 width=250 align=center class="menu">
<tr style="cursor: hand;">
<td height=25 class=menu_title background=xpmenu/title_bg_hide.gif
id=menuTitle1 class="menu">
<span>用户登录</span>
</td>
</tr>
<tr>
<td>
<div class=sec_menu id=menu1>
<table cellpadding=2 cellspacing=0 align=center width=250
style="position: relative; top: 10px;">
<tr>
<td>
<form action="/sshtest/login.do" method="post" name="loginForm"
id="loginForm" OnSubmit="return logcheckCode(this);">
<table width="100%" border="0" cellspacing="0" cellpadding="3"
align="center">
<tr>
<td align="center">
用户名 :
</td>
<td>
<input type="text" name="username"
size="20">
</td>
</tr>
<tr>
<td align="center">
密 码 :
</td>
<td>
<input type="password" name="password"
size="22">
</td>
</tr>
<tr>
<td align="center">
验证码 :
</td>
<td>
<input type="text" name="randCode" size="4" id="randCode"
onBlur="checkCodeLogin()" />
<img src="<%=basePath%>\ChineseVal.jsp"
onclick="this.src+='?' + Math.random();">
</td>
</tr>
<tr>
<td></td>
<td>
<FONT color=red><span id="randCodeResult"></span>
</FONT>
</td>
</tr>
<tr align="center">
<td colspan="2">
<input type="hidden" name="usermethod" value="findUser">
<input type="submit" name="submit" id="formstyleall"
value="登录">
  
<input type="reset" name="reset" id="formstyleall"
value="取消">
</td>
</tr>
</table>
</form>
</td>
</tr>
<tr>
<h4>
<td align="center">
<a href="<%=path %>/form/register.jsp"
target="main">注册</a> - -
<a
href="<%=path %>/form/findPassword.jsp"
target="main"">忘记密码</a>
</h4>
</td>
</tr>
<tr>
<td height=20>
<!--spacer-->
</td>
</tr>
</table>
</div>
</td>
</tr>
</table>
</body>
</html>
<!--Start XP Style Menu-->
<SCRIPT LANGUAGE="Javascript" DEFER="TRUE">
<!--
var menuinit=new Array(50),vers;//(don't change this)
for(i=0;i<51;i++)menuinit[i]=new Array(3);//(don't change this)
////////////////////////////////////////////////////////////////////////////////////////
//
vers="XP Style Menu SP2(V2002.12.10.1452 NEW_CORE_DEV_BETA build 69)";
//
//Improved by: swnet(swnet@263.net)
//Original by: Zhong Zhong
//
//Note: best work with MS IE5/6, also looks fine on Netscape/Mozilla but without
// visualized effect.
//
//*THIS CODE IS UNDER GUN GPL LICENCE*
////////////////////////////////////Setting Section////////////////////////////////////
//
var onemenu = 0; //open one menu at same time.1 is yes, 0 is no. default=1.
var speedmout = 100; //menu show speed(1~100;default=50) *the large the fast, but also come with more bump.
var speedmin = 100; //menu hide speed(1~100;default=50)
var developversion = true; //when false block all script error if any.
//setting of which menu should be showen. In this example you have 4 menu, which you can switch between "show" and "not show"
//if you want to add extra one, you should follow this order: "menuinit[n][1]=;" (in [a][b], b must be '1', a is the serial number of menu)
menuinit[1][1]="show";
menuinit[2][1]="show";
menuinit[3][1]="show";
menuinit[4][1]="show";
menuinit[5][1]="show";
menuinit[6][1]="show";
menuinit[7][1]="show";
menuinit[8][1]="show";
////////////////////////!!!DO NOT CHANGE BELOW THIS LINE!!!!/////////////////////////////
//
var da=new Date();
var browser=new BrowserDetectLite();
var fstrun=1;
var op="";
var whichContinue="";
var whichOpen="";
var opp=0;
var opd=0;
var opc=0;
var sc=1;sd=1;
var mnunum=0;
var cacheObj,cacheMaxh,cacheObj2;
//----------------------------------------------------------------------------------------
//--------向下显示内容--------
function menuShow(obj,maxh,obj2)
{
var da=new Date();
if(fstrun==1){
op="show";
mountmfunc(0,0,0);
obj2.background="xpmenu/title_bg_hide.gif";
obj.style.pixelHeight=2;
obj.style.display='block';
opc=6.18*(speedmout*0.01); //step length
opp=Math.round(opc); //rounded step length
opd=(maxh/opp)/100; //times
sc=1;sd=opd;
fstrun=0;
cacheObj=obj;cacheMaxh=maxh;cacheObj2=obj2;
}else{
if(op!="show") return false;
}
if(obj.style.pixelHeight<maxh-opp)
{
if(opd>1){//for slow speed
if(sd-sc<1){obj.filters.alpha.opacity+=1;sd+=opd;}
sc++;
}else{//for fast speed
obj.filters.alpha.opacity+=Math.ceil(1/opd);
}
obj.style.pixelHeight+=opp;
cacheObj=obj;cacheMaxh=maxh;cacheObj2=obj2;
setTimeout('menuShow(cacheObj,cacheMaxh,cacheObj2)','5');
}else{
obj.style.pixelHeight=maxh;
obj.filters.alpha.opacity=100;
fstrun=1;
op="";
sc=1;sd=1;
mountmfunc(1,1,1);
return true;
}
}
//----------------------------------------------------------------------------------------
//--------向上隐藏内容--------
function menuHide(obj,maxh,obj2)
{
da=new Date();
if(fstrun==1){
op="hide";
mountmfunc(0,0,0);
obj2.background="xpmenu/title_bg_show.gif";
opc=6.18*(speedmout*0.01); //step length
opp=Math.round(opc);
opd=((maxh-3)/opp)/100;
sc=1;sd=opd;
fstrun=0;
cacheObj=obj;cacheMaxh=maxh;cacheObj2=obj2;
}else{
if(op!="hide") return false;
}
if(obj.style.pixelHeight-opp>1)
{
if(opd>1){
if(sd-sc<1){obj.filters.alpha.opacity-=1;sd+=opd;}
sc++;
}else{
obj.filters.alpha.opacity-=Math.ceil(1/opd)*0.38;
}
obj.style.pixelHeight-=opp;
setTimeout('menuHide(cacheObj,cacheMaxh,cacheObj2)','5');
}else{
obj.style.pixelHeight=1;
obj.style.display='none';
obj.filters.alpha.opacity=0;
fstrun=1;
op="";
sc=1;sd=1;
mountmfunc(1,1,1);
if(whichContinue && onemenu==1) whichContinue.click();
return true;
}
}
//----------------------------------------------------------------------------------------
//--------必要函数--------
function menuChange(obj,maxh,obj2)
{
if(obj.style.pixelHeight>1)
{
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -