资源简介
054JSP学生勤工俭学系统054JSP学生勤工俭学系统054JSP学生勤工俭学系统
代码片段和文件信息
package com.action;
/**
*
* 留言本
*/
import java.io.IOException;
import java.util.List;
import javax.servlet.ServletException;
import javax.servlet.http.HttpServlet;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import javax.servlet.http.HttpSession;
import com.bean.GuestBookBean;
import com.bean.SystemBean;
import com.util.Constant;
import com.util.Filter;
public class GuestBookAction extends HttpServlet {
/**
* Constructor of the object.
*/
public GuestBookAction() {
super();
}
/**
* Destruction of the servlet.
*/
public void destroy() {
super.destroy(); // Just puts “destroy“ string in log
// Put your code here
}
/**
* The doGet method of the servlet.
*
* This method is called when a form has its tag value method equals to get.
*
* @param request the request send by the client to the server
* @param response the response send by the server to the client
* @throws ServletException if an error occurred
* @throws IOException if an error occurred
*/
public void doGet(HttpServletRequest request HttpServletResponse response)
throws ServletException IOException {
doPost(requestresponse);
}
/**
* The doPost method of the servlet.
*
* This method is called when a form has its tag value method equals to post.
*
* @param request the request send by the client to the server
* @param response the response send by the server to the client
* @throws ServletException if an error occurred
* @throws IOException if an error occurred
*/
public void doPost(HttpServletRequest request HttpServletResponse response)
throws ServletException IOException {
request.setCharacterEncoding(Constant.CHARACTERENCODING);
response.setContentType(Constant.CONTENTTYPE);
//nikename pic email qq weburl blogurl expressions content
String sysdir = new SystemBean().getDir();
HttpSession session = request.getSession();
String method = request.getParameter(“method“).trim();
GuestBookBean guestBookBean = new GuestBookBean();
if(method.equals(“add“)){//发表留言
String member=(String)session.getAttribute(“member“);
String nikename = Filter.escapeHTMLTags(request.getParameter(“nikename“).trim());
String face =“images/nobody.gif“;
String email = Filter.escapeHTMLTags(request.getParameter(“email“).trim());
String qq = Filter.escapeHTMLTags(request.getParameter(“qq“).trim());
String weburl = Filter.escapeHTMLTags(request.getParameter(“weburl“).trim());
String blogurl = Filter.escapeHTMLTags(request.getParameter(“blogurl“).trim());
String expressions = “images/face/“+Filter.escapeHTMLTags(request.getParameter(“face“).trim())+“.gif“;
String content = Filter.escapeHTMLTags(request.getParameter(“content“).trim());
String ip = request.getRemoteAddr();
int guestbook=1;
int flag = guestBookB
属性 大小 日期 时间 名称
----------- --------- ---------- ----- ----
目录 0 2016-03-15 09:56 054JSP学生勤工俭学系统\
目录 0 2016-03-15 09:56 054JSP学生勤工俭学系统\勤工兼学\
目录 0 2016-03-15 09:49 054JSP学生勤工俭学系统\勤工兼学\qgjx\
文件 1495 2012-05-05 23:23 054JSP学生勤工俭学系统\勤工兼学\qgjx\.classpath
目录 0 2016-03-15 09:49 054JSP学生勤工俭学系统\勤工兼学\qgjx\.myeclipse\
文件 285 2012-05-09 23:44 054JSP学生勤工俭学系统\勤工兼学\qgjx\.myme
文件 1222 2012-05-05 23:24 054JSP学生勤工俭学系统\勤工兼学\qgjx\.project
目录 0 2016-03-15 09:49 054JSP学生勤工俭学系统\勤工兼学\qgjx\src\
目录 0 2016-03-15 09:49 054JSP学生勤工俭学系统\勤工兼学\qgjx\src\com\
目录 0 2016-03-15 09:57 054JSP学生勤工俭学系统\勤工兼学\qgjx\src\com\action\
文件 6986 2012-05-05 23:22 054JSP学生勤工俭学系统\勤工兼学\qgjx\src\com\action\GuestBookAction.java
文件 6205 2012-05-05 23:22 054JSP学生勤工俭学系统\勤工兼学\qgjx\src\com\action\LoginAction.java
目录 0 2016-03-15 09:57 054JSP学生勤工俭学系统\勤工兼学\qgjx\src\com\bean\
文件 12956 2012-05-05 23:22 054JSP学生勤工俭学系统\勤工兼学\qgjx\src\com\bean\AfficheBean.java
文件 4278 2012-05-05 23:22 054JSP学生勤工俭学系统\勤工兼学\qgjx\src\com\bean\ComBean.java
文件 3225 2012-05-05 23:22 054JSP学生勤工俭学系统\勤工兼学\qgjx\src\com\bean\Friendli
目录 0 2016-03-15 09:57 054JSP学生勤工俭学系统\勤工兼学\qgjx\src\com\util\
文件 318 2012-05-05 23:22 054JSP学生勤工俭学系统\勤工兼学\qgjx\src\com\util\CheckCode.java
文件 1838 2012-05-05 23:22 054JSP学生勤工俭学系统\勤工兼学\qgjx\src\com\util\Common.java
文件 533 2012-05-05 23:22 054JSP学生勤工俭学系统\勤工兼学\qgjx\src\com\util\Constant.java
文件 2636 2012-05-05 23:39 054JSP学生勤工俭学系统\勤工兼学\qgjx\src\com\util\DBO.java
文件 650 2012-05-05 23:22 054JSP学生勤工俭学系统\勤工兼学\qgjx\src\com\util\Filter.java
文件 836 2012-05-05 23:22 054JSP学生勤工俭学系统\勤工兼学\qgjx\src\com\util\Log.java
文件 792 2012-05-05 23:22 054JSP学生勤工俭学系统\勤工兼学\qgjx\src\com\util\MD5.java
目录 0 2016-03-15 09:49 054JSP学生勤工俭学系统\勤工兼学\qgjx\WebRoot\
目录 0 2016-03-15 09:57 054JSP学生勤工俭学系统\勤工兼学\qgjx\WebRoot\admin\
目录 0 2016-03-15 09:49 054JSP学生勤工俭学系统\勤工兼学\qgjx\WebRoot\admin\affiche\
文件 4054 2012-05-05 23:22 054JSP学生勤工俭学系统\勤工兼学\qgjx\WebRoot\admin\affiche\edit.jsp
文件 4365 2012-05-05 23:22 054JSP学生勤工俭学系统\勤工兼学\qgjx\WebRoot\admin\affiche\index.jsp
目录 0 2016-03-15 09:49 054JSP学生勤工俭学系统\勤工兼学\qgjx\WebRoot\admin\guestbook\
文件 8129 2012-05-05 23:22 054JSP学生勤工俭学系统\勤工兼学\qgjx\WebRoot\admin\guestbook\index.jsp
............此处省略707个文件信息
- 上一篇:百度语音识别Android Studio版
- 下一篇:文字识别Tess4J配置与
评论
共有 条评论