package com.homeinns.web.servlet;
import java.io.IOException;
import javax.servlet.ServletException;
import javax.servlet.http.HttpServlet;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
public class DemoAction extends HttpServlet {
	private static final long serialVersionUID = 1L;
	protected void doGet(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException {
		doPost(request, response);
	}
	protected void doPost(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException {
		request.setCharacterEncoding("utf-8");
		response.setCharacterEncoding("utf-8");
		String msg = "您上传了：<br/>";
		String[] fileUrls = request.getParameterValues("fileUrl");
		String[] fileNames = request.getParameterValues("fileName");
		for (int i = 0; i < fileUrls.length; i++) {
			msg += "文件路径：" + fileUrls[i] + " 文件名称：" + fileNames[i] + "<br/>";
			// System.out.println(fileUrls[i] + " " + fileNames[i]);
		}
		String name = request.getParameter("name");
		msg += "用户名：" + name + "<br/>";
		String pwd = request.getParameter("pwd");
		msg += "密码：" + pwd + "<br/>";
		request.setAttribute("msg", msg);
		request.getRequestDispatcher("/success.jsp").forward(request, response);
	}
}

@@ -19,32 +19,33 @@
 ns.web.servlet;%0A
+%0A
 import java.io.I
@@ -227,16 +227,17 @@
 sponse;%0A
+%0A
 public c
@@ -324,16 +324,17 @@
 D = 1L;%0A
+%0A
 %09protect
@@ -366,33 +366,36 @@
 Request request,
- 
+%0A%09%09%09
 HttpServletRespo
@@ -479,16 +479,17 @@
 se);%0A%09%7D%0A
+%0A
 %09protect
@@ -530,17 +530,20 @@
 request,
- 
+%0A%09%09%09
 HttpServ
@@ -961,11 +961,8 @@
 %0A%09%09%09
-// 
 Syst

Modify Code add log !