欢迎来到三一办公! | 帮助中心 三一办公31ppt.com(应用文档模板下载平台)
三一办公
全部分类
  • 办公文档>
  • PPT模板>
  • 建筑/施工/环境>
  • 毕业设计>
  • 工程图纸>
  • 教育教学>
  • 素材源码>
  • 生活休闲>
  • 临时分类>
  • ImageVerifierCode 换一换
    首页 三一办公 > 资源分类 > DOC文档下载  

    JSP个人网站留言板课程设计.doc

    • 资源ID:2399740       资源大小:582KB        全文页数:24页
    • 资源格式: DOC        下载积分:8金币
    快捷下载 游客一键下载
    会员登录下载
    三方登录下载: 微信开放平台登录 QQ登录  
    下载资源需要8金币
    邮箱/手机:
    温馨提示:
    用户名和密码都是您填写的邮箱或者手机号,方便查询和重复下载(系统自动生成)
    支付方式: 支付宝    微信支付   
    验证码:   换一换

    加入VIP免费专享
     
    账号:
    密码:
    验证码:   换一换
      忘记密码?
        
    友情提示
    2、PDF文件下载后,可能会被浏览器默认打开,此种情况可以点击浏览器菜单,保存网页到桌面,就可以正常下载了。
    3、本站不支持迅雷下载,请使用电脑自带的IE浏览器,或者360浏览器、谷歌浏览器下载即可。
    4、本站资源下载后的文档和图纸-无水印,预览文档经过压缩,下载后原文更清晰。
    5、试题试卷类文档,如果标题没有明确说明有答案则都视为没有答案,请知晓。

    JSP个人网站留言板课程设计.doc

    JIANGXI AGRICULTURAL UNIVERSITYJSP课程设计报告 题目: 个人网站留言板系统程序设计 学 院: 软件学院 姓 名: 周婷 学 号: 20102024 专 业: 软件+英语 班 级: 软件1013班 指导教师: 邓泓 二0一二 年 九 月摘 要个人网站留言板及用户注册系统是一个针对个人而开发的网站系统,个人网站是一个可以发布个人信息及相关内容。通俗理解个人网站:就是指网站内容是介绍自己的或是以自己的信息为中心的网站,访客可以在网站注册后留言。本网站是一个典型的简单的个人网站系统,其开发主要包括后台数据库的建立和维护以及前端WEB页面的设计两个方面。对于前者要求建立起数据一致性和完整性强、数据安全性好的库,不会出现增加,删除,修改的异常。而对于后者则要求应用功能完备,易使用,界面友好等特点。另外,本文还着重论述了留言板和用户注册系统的功能与实现,包括数据流程及存储、注册用户管理、留言板信息管理、用户权限管理、用户密码管理、留言信息和用户的增加、留言信息的删除、留言信息的查询、注册用户的查询、等。本系统提供管理员、访客的登录。管理员可以查看用户注册信息和留言信息,可对其进行删除修改等功能。访客登录可以在留言板上留言。关键词:个人网站;访客;管理员;留言板AbstractPersonal website message board and user registration system are web site developed for individual systems, personal Web site can publish a personal information and related content. Popular understanding of website: that the content of a site is to introduce their own information, or to the center of the site, visitors can leave a message after the site up. This site is a typical simple personal website system, which mainly includes the establishment and maintenance of back-end database and front two aspects of the design of WEB pages. Request for the establishment of data consistency and integrity, data security and good libraries, does not appear to add, delete, modify the exception. For the latter requires the application of functions, easy to use, friendly interface and so on. In addition, this paper focuses on the message boards and user registration system function and implementation, including data flow and storage, the registered user management, message board information management, user rights management, user password management, message information and user increases, voice messages delete, the message information query, the query registered users, and so on. The system administrator, visitor login. Administrators can view the user registration information and message information, can be modified to delete its functions. Visitors can sign up for casual users log in and use the user a message.Keywords: Personal website; Visitor; Managor;Message board目 录1第一章 课题背景51.1 课程要求51.2设计概要51.3工具及环境简介52第二章 设计简介及设计方案论述52.1 系统功能概述52.1.1 用户类型62.1.2 管理员62.1.3 普通用户62.2 数据库设计72.2.1管理员息表:72.2.2注册用户留言信息表:73第三章 详细设计73.1 首页设计73.1.1 管理员登录143.2 管理员审核留言信息174第四章 设计结果及分析184.1 首页界面结果184.1.1首页界面如下:184.1.2 管理员登录184.2 留言板信息管理194.2.1 留言内容信息194.2.2 删除用户信息194.2.3 审核通过用户信息204.2.4 审核不通过用户留言信息214.2.5 敏感词的过滤实现224.3 留言管理224.3.1 查看用户留言信息224.4 结果分析235总 结241 第一章 课题背景1.1 课程要求内容概要:个人网站留言板设计与实现。具体要求如下:1) 用户留言信息(留言内容的新增、删除、修改);2) 管理员登陆;3) 管理员可对用户留言信息进行管理;4) 判断用户标识和口令,并进行权限管理;5) 进行敏感词的过滤。1.2设计概要本系统是一个基于JSP平台及JDBC和ODBC接口技术访问MySQL机制的网络留言板。该网站系统基本实现了网络留言等功能。系统包括前台(用户)和后台(管理员)两部分,前台包括网友留言、留言查看等几个模块,后台包括留言管理,管理员管理留言信息等模块。网页中的文字及链接文字都用css样式统一风格,布局合理。该网站页面条理清晰,具有操作方便,功能完善,易于管理等特点。1.3工具及环境简介 本系统是在window平台上,采用JSP集成开发环境MyEclipse6.0.1版本。2 第二章 设计简介及设计方案论述2.1 系统功能概述根据用户权限不同可以将本系统分为2大模块,分别为:管理员用户权限、访客用户权限。本系统各个部分及其包括的具体功能模块如下图所示:2.1.1 用户类型用户普通用户管理员图21-1用户类型逻辑图2.1.2 管理员图21-2管理员权限逻辑图2.1.3 普通用户图21-3管理员权限逻辑图2.2 数据库设计 在设计网站时,我们采用了通过SQL数据库语句建立表,在设计表时,首先设计了2个基本的表,分别记录管理员信息和留言信息。2.2.1管理员息表:图2-2-12.2.2注册用户留言信息表:图2 - 33 第三章 详细设计3.1 首页设计本系统的首页由图片用户名,留言主题,用户邮箱,地址,头像,iqcq,我的主页以及留言内容组成,根据访客的不同需求选择不同的界面,并且加入了必须填写所有信息的JavaScript特效。代码如下:<% page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8" import="com.zhou.util.*,java.sql.*"%><% Boolean isLogin=(Boolean)session.getAttribute("isLogin"); Connection conn=null; PreparedStatement pstmt=null; ResultSet rs=null; conn=DBUtil.getConn(); pstmt=DBUtil.getPstmt(conn,"select * from t_msg"); rs=pstmt.executeQuery(); %><!DOCTYPE html PUBLIC "-/W3C/DTD HTML 4.01 Transitional/EN" "http:/www.w3.org/TR/html4/loose.dtd"><html><head><title>周婷的留言板</title><meta http-equiv="Content-Type" content="text/html; charset=gb2312"><link href="index.css" rel="stylesheet" type="text/css"><script type="text/javascript" src="./global.js"></script></head><body bgcolor="#FFFFFF" leftmargin="0" topmargin="0" marginwidth="0" marginheight="0"><center><!- ImageReady Slices (index.jpg) -><table id="_01" width="990" height="793" border="0" cellpadding="0" cellspacing="0"><tr><td rowspan="7"><img src="images/index_08.gif" width="12" height="631" alt=""></td><td height="27" colspan="2" class="tdfont" background="images/index_09_repeat.gif">&nbsp;<a href="#">留言首页</a></td><td rowspan="7"><img src="images/index_10.gif" width="7" height="631" alt=""></td></tr><tr><td colspan="2"><marquee class="tdfont" vspace="5" scrollamount="3" height="15" width="500" align="middle" onMouseOver="this.stop()" onMouseOut="this.start()"><a href="#">欢迎来到周婷的留言板!</a></marquee></td></tr><tr><td colspan="2"><table width="762" bordercolor="#FF6600" cellspacing="0" cellpadding="0" border="1"> <tr align="center" class="tdfont"> <td height="27" width="200" background="images/index_09_repeat.gif">留言作者</td> <td height="27" background="images/index_09_repeat.gif">留言信息</td> </tr> <!- start -> <% int floor=1; while(rs.next() %> <tr> <td><table width="200" cellspacing="0" cellpadding="0" border="0"> <tr> <td colspan="3" align="center"><img src="images/<%=rs.getString("photo") %>.gif" width="75" height="75"></td> </tr> <tr class="tdfont"> <td align="right">NO:<%=floor+ %></td> <td width="22" height="15" ><img src="images/logo_sanjiao.gif"></td> <td align="left" width="90"><%=rs.getString("username") %></td> </tr> </table></td> <td valign="top"><table width="562" cellspacing="0" cellpadding="0" border="0"> <tr> <td align="left" class="tdfont" width="200">标题:<%=rs.getString("title") %></td> <td>&nbsp;</td> <td align="left" class="tdfont" width="100">时间:<%=rs.getString("pdate") %> <% if(isLogin!=null && isLogin) %> <a href="./del.jsp?id=<%=rs.getString("id") %>">删除</a>&nbsp;&nbsp; <a href="./updateState.jsp?state=2&id=<%=rs.getString("id") %>">审核通过</a>&nbsp;&nbsp; <a href="./updateState.jsp?state=3&id=<%=rs.getString("id") %>">审核未通过</a>&nbsp;&nbsp; <% %> </td> <td>&nbsp;</td> <td>&nbsp;</td> <td width="19" height="16"><img src="images/icon_profile.gif" alt="住址" width="16" height="16"></td> <td width="19" height="16"><img src="images/icon_email.gif" alt="邮箱" width="16" height="16"></td> <td width="19" height="16"><img src="images/icon_editor_oicq.gif" alt="IQCQ" width="16" height="16"></td> <td width="19" height="16"><img src="images/icon_homepage.gif" alt="主页" width="16" height="16"></td> <td width="19" height="16"><img src="images/icon_ip.gif" alt="IP" width="16" height="16"></td> </tr> <tr> <td colspan="10" height="75" background="images/index_09_repeat1.gif">&nbsp; <% int state = rs.getInt("state"); if(state=1) out.print("-管理员未审核-"); else if(state=2) out.print(rs.getString("content"); else out.print("-审核未通过-"); if(isLogin!=null && isLogin) out.print("</br>"+rs.getString("content"); %> </td> </tr> </table></td> </tr> <% DBUtil.close(conn,pstmt,rs); %> <!- end -></table></td></tr><tr height="27"><td valign="bottom" colspan="2" width="762" height="27" background="images/index_09_repeat.gif"></td></tr><tr><td colspan="2"><img src="images/index_14.gif" width="762" height="9" alt=""></td></tr><tr><td colspan="2" width="762" height="380"><!- START -><form action="addMsg.jsp" name="note" method="post" onsubmit="return check()"> <table class="tdfont" width="762" height="380" border="1" cellpadding="0" cellspacing="0" bordercolor="orange"> <tr align="center"> <td height="28" colspan="2" background="images/index_09_repeat.gif"><font style="font-weight:bold; color:ffffff">签写留言</font> </td> </tr> <tr> <td width="233" height="28" align="right">你的名字:</td> <td width="523" height="28"><label> <input type="text" name="username" /> *(必填)</label></td> </tr> <tr> <td height="28"><div align="right">留言主题:</div></td> <td height="28"><label> <input name="title" type="text" size="40" /> *(必填)</label></td> </tr> <tr> <td height="28"><div align="right">电子邮件:</div></td> <td height="28"><label> <input type="text" name="email" /> *(必填)</label></td> </tr> <tr> <td height="28"><div align="right">来自何方:</div></td> <td height="28"><label> <select name="address"> <option value="1">江西</option> <option value="2">北京</option> <option value="3">深圳</option> </select> *(必填)</label></td> </tr> <tr> <td height="28"><div align="right">头像:</div></td> <td height="28"><label> <select name="photo"> <option value="1">头像1</option> <option value="2">头像2</option> <option value="3">头像3</option> </select> </label> *(必填)</td> </tr> <tr> <td height="28"><div align="right">IQCQ:</div></td> <td height="28"><label> <input type="text" name="iqcq" /> *(必填)</label></td> </tr> <tr> <td height="28"><div align="right">我的主页:</div></td> <td height="28"><label> <input type="text" name="mypage" /> *(必填)</label></td> </tr> <tr> <td><div align="right">留言内容:</div></td> <td><textarea name="content" cols="55" rows="10"></textarea>*(必填)</td> </tr> <tr> <td height="28">&nbsp;</td> <td height="28" ><input name="pdate" type="image" src="images/button_note_tijiao.gif" /> 按CTRL+ENTER直接发表 <label> <input type="checkbox" name="checkbox" value="checkbox" /> 只有管理员才能看</label></td> </tr></table></form><!- END -></td></tr><tr><td colspan="2" ><img src="images/index_16.gif" width="762" height="17" alt=""></td></tr><tr><td align="center" class="tdfont" colspan="4" width="781" height="37" background="images/foot_repeate.gif"> <a href="./login.jsp">管理员登陆</a></td></tr><tr><td><img src="images/分隔符.gif" width="104" height="1" alt=""></td><td><img src="images/分隔符.gif" width="12" height="1" alt=""></td><td><img src="images/分隔符.gif" width="164" height="1" alt=""></td><td><img src="images/分隔符.gif" width="598" height="1" alt=""></td><td><img src="images/分隔符.gif" width="7" height="1" alt=""></td><td><img src="images/分隔符.gif" width="105" height="1" alt=""></td></tr></table><!- End ImageReady Slices -></center></body></html>3.1.1 管理员登录系统在管理员登录时要验证管理员的ID和密码,正确才能进入系统,否则提示输入用户名和密码不正确。代码如下: <% page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8" import="com.zhou.util.*,java.sql.*"%><% String command=request.getParameter("command"); if(command!=null&&"login".equals(command) String username=request.getParameter("username"); String password=request.getParameter("password"); Connection conn=null; PreparedStatement pstmt=null; ResultSet rs=null; conn=DBUtil.getConn(); pstmt=DBUtil.getPstmt(conn,"select password from t_admin where username=?"); pstmt.setString(1,username); rs=pstmt.executeQuery(); if(rs.next() if(!password.equals(rs.getString("password") request.setAttribute("msg","密码错误!"); request.setAttribute("path","./login.jsp"); else request.setAttribute("msg","登陆成功!"); request.setAttribute("path","./index.jsp"); session.setAttribute("isLogin",true); else request.setAttribute("msg","用户名没有找到!"); request.setAttribute("path","./login.jsp"); request.getRequestDispatcher("./msg.jsp").forward(request,response); return; %><!DOCTYPE html PUBLIC "-/W3C/DTD HTML 4.01 Transitional/EN" "http:/www.w3.org/TR/html4/loose.dtd"><html><head><link href="index.css" rel="stylesheet" type="text/css"><title>login_index</title><meta http-equiv="Content-Type" content="text/html; charset=gb2312"></head><body bgcolor="#FFFFFF" leftmargin="0" topmargin="0" marginwidth="0" marginheight="0"><center><!- ImageReady Slices (login_index.jpg) -><table id="_01" width="990" height="320" border="0" cellpadding="0" cellspacing="0"><tr><td rowspan="6"><img src="images/login_index_01.gif" width="102" height="320" alt=""></td><td colspan="5"></td><td rowspan="6"><img src="images/login_index_03.gif" width="104" height="320" alt=""></td></tr><tr><td rowspan="4"><img src="images/login_index_05.gif" width="12" height="198" alt=""></td><td height="27" colspan="3" class="tdfont" background="images/index_09_repeat.gif">&nbsp;<a href="#">留言首页</a></td><td rowspan="4"><img src="images/login_index_07.gif" width="8" height="198" alt=""></td></tr><tr><td colspan="3"><img src="images/login_index_08.gif" width="764" height="20" alt=""></td></tr><tr><td rowspan="2"><img src="images/login_index_09.gif" width="29" height="148" alt=""></td><td width="707" height="120"><form action="./login.jsp" name="login" method="post"><input type="hidden" name="command" value="login"> <table class="tdfont" width="707" height="120" border="1" cellpadding="0" cellspacing="0" bordercolor="orange"> <tr align="center"> <td height="28" colspan="2" background="images/index_09_repeat.gif"><font style="font-weight:bold; color:ffffff">管理员登陆</font></td> </tr> <tr> <td width="233" height="28" align="right">用户名:</td> <td width="523" height="28"><label> <input type="text" name="username" /> *(必填)</label></td> </tr> <tr> <td height="28"><div align="right">密码:</div></td> <td height="28"><label> <input type="password" name="password" /> *(必填)</label></td> </tr> <tr> <td height="28">&nbsp;</td>

    注意事项

    本文(JSP个人网站留言板课程设计.doc)为本站会员(仙人指路1688)主动上传,三一办公仅提供信息存储空间,仅对用户上传内容的表现方式做保护处理,对上载内容本身不做任何修改或编辑。 若此文所含内容侵犯了您的版权或隐私,请立即通知三一办公(点击联系客服),我们立即给予删除!

    温馨提示:如果因为网速或其他原因下载失败请重新下载,重复下载不扣分。




    备案号:宁ICP备20000045号-2

    经营许可证:宁B2-20210002

    宁公网安备 64010402000987号

    三一办公
    收起
    展开