1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21
|
public class UpdateProf extends HttpServlet{
// je construis ma page html
public void doGet(HttpServletRequest request, HttpServletResponse
reponse) throws IOException, ServletException {
response.setContentType("text/html");
PrintWriter out = response.getWriter();
out.println("<html>");
..........
..............
out.println("<FORM Method='POST'>");
......................
}
// et la je traite les donné issu du form
public void doPost(HttpServletRequest req, HttpServletResponse res)throws ServletException, IOException {
res.setContentType("text/html");
ServletOutputStream out = res.getOutputStream();
String num=req.getParameter("numero" );
..................
... |
Partager