一个applet---servlet通讯的例子---servlet文件

发表于:2007-07-04来源:作者:点击数: 标签:
import java.io.*;
import java.util.Date;
import javax.servlet.*;
import javax.servlet.http.*;
public void Riceive extends HttpServlet
{
    public void service(HttpServletRequest req,HttpServletResponse res) throws ServletException,IOException
    {
         res.setContenType("text/plain");
         ServletOutputStream out=res.getOutputStream();
         out.print("recive user message:");
         out.print(req.getParameter("message"));
    
    
    }//end service
    
}//end receive

原文转自:http://www.ltesting.net