毕业论文论文范文课程设计实践报告法律论文英语论文教学论文医学论文农学论文艺术论文行政论文管理论文计算机安全
您现在的位置: 毕业论文 >> 论文 >> 正文

JSP在线CD销售系统

更新时间:2007-11-1:  来源:毕业论文

ASP在线CD销售系统|计算机专业全套免费毕业设计论文网,因为源代码过多,我只粘贴部分源代码,需要全部代码的,可以联系站长QQ752018766,本毕业设计免费,谢谢支持

JSP登录系统源代码:login.jsp

<%@ page contentType="text/html;charset=gb2312" %>
<%@ page session="true" %>
<jsp:useBean id="login" scope="page" class="cdshop.run.login" />
<%
String mesg = "";

if( request.getParameter("username")!=null && !request.getParameter("username").equals("")){
 String username =request.getParameter("username");
 String passwd = request.getParameter("passwd");
 username = new String(username.getBytes("ISO8859-1"));
 passwd = new String(passwd.getBytes("ISO8859-1"));
 login.setUsername(username);
 login.setPasswd(passwd);
 out.print(username+passwd);
 if (login.excute()){
  session.setAttribute("username",username);
  String userid = Long.toString(login.getUserid());
  session.setAttribute("userid",userid);
  response.sendRedirect("cdlist.jsp");
  %>
<% 
 }else {
 mesg = "登录出错!" ;
 }
}
%>
<%@include file="inc/head.inc"%>

<script language="javascript">

 function checkform() {
 if (document.form1.username.value=="" || document.form1.passwd.value==""){
  alert("用户名或密码为空!");
  return false;
 }
 return true;

  }

</script>
<div align=center>用户登录 </div>
          <br>         
<% if (!mesg.equals("")){
      out.println("<p>" + mesg + "</p>");}%>
      
  <form name="form1" method="post" action="login.jsp">
    <table width="400" border="0" cellspacing="1" cellpadding="1" align="center">
    <tr>
      <td width="147" align="right">用户名:<br>
      </td>
      <td width="246" valign="top">
          <input type="text" name="username" size="16" maxlength="25">
        </td>
    </tr>
    <tr>
      <td width="147" align="right">密码:</td>
      <td width="246" valign="top">
          <input type="password" name="passwd" maxlength="20" size="16">
        </td>
    </tr>
    <tr>
      <td width="147" align="right">&nbsp;</td>
      <td width="246" valign="top">
          <input type="submit" name="Submit" value="登录" onclick="javascript:return(checkform());">
          <input type="reset" name="Submit2" value="取消">
        </td>
    </tr>
    <tr>    
      <td colspan="2" align="center">
        <p>&nbsp;</p>
        测试用户:1 密码:1
      </td>
    </tr>
    <tr>
   
      <td colspan="2" align="center">
        <p>&nbsp;</p>
        <p>如果你还不是本站用户,请在此<a href="reg.jsp">注册</a></p>
      </td>
    </tr>
  </table>
    </form>
 <%@include file="inc/tail.inc"%>

首页源代码:index.jps

<%@ page contentType="text/html;charset=gb2312" %>
<%@ page import="java.util.*" %>
<%@ page session="true" %>
<%@include file="inc/head.inc"%>
<br>

  <form name="form1" method="post" action="login.jsp">
          <div align=center>用户登录 </div>
          <br>         
          <table width="300" border="0" cellspacing="1" cellpadding="1" align="center"  bgcolor="#FFCC99">
          <br>
            <tr>
              <td align="right">用户名:</td>
              <td>
                <input type="text" name="username" size="15" maxlength="25">
              </td>
            </tr>
            <tr>
              <td align="right">密码:</td>
              <td>
                <input type="password" name="passwd" size="15" maxlength="20">
              </td>
            </tr>
            <tr>
              <td colspan="2" align="center">
                <input type="submit" name="Submit" value="登录">
             
                <input type="reset" name="Submit2" value="取消">
              </td>
            </tr>
             <tr>    
            <td colspan="2" align="center">
          <p>&nbsp;</p>
             测试用户:1 密码:1
        </td>
        </tr>
            <tr>
              <td colspan="2" align=center>如果不是本站会员,请在此<a href="reg.jsp">注册</a>。</td>             
            </tr>
         </table>
   </form>

<%@include file="inc/tail.inc"%>

[1] [2] [3] [4] [5] 下一页

JSP在线CD销售系统下载如图片无法显示或论文不完整,请联系qq752018766
设为首页 | 联系站长 | 友情链接 | 网站地图 |

copyright©youerw.com 优文论文网 严禁转载
如果本毕业论文网损害了您的利益或者侵犯了您的权利,请及时联系,我们一定会及时改正。