login.jsp
<%@ page language= "Java"Import= "java.util.*" pageencoding= "Utf-8"%><%String Path=Request.getcontextpath (); String BasePath= Request.getscheme () + "://" +request.getservername () + ":" +request.getserverport () +path+ "/";%><! DOCTYPE HTML PUBLIC "-//w3c//dtd HTML 4.01 transitional//en" >Guestbook:<br> <textarea name= "re" id= "Re" cols= "rows=" 5 "></textarea><br> <input type=" Submit " Name= "Submit" value= "Submission"/> </form> </body><ml>
login_deal.jsp
<%@ page language= "Java"Import= "java.util.*" pageencoding= "Utf-8"%><%String Path=Request.getcontextpath (); String BasePath= Request.getscheme () + "://" +request.getservername () + ":" +request.getserverport () +path+ "/";%><! DOCTYPE HTML PUBLIC "-//w3c//dtd HTML 4.01 transitional//en" >String re=request.getparameter ("Re"); Out.println ("Your message is:" +re); %> </body><ml>
4-1: Write a simple guestbook, write the message after the submission of the message content.