Consists of three files: jsp_include.jsp, static.html, two.jsp
Surrounding environment: tomcat7.0. Myeclipse10
1.jsp_include.jsp
<%@ page contenttype= "Text/html;charest=utf-8" language= "java"%><! DOCTYPE HTML PUBLIC "-//w3c//dtd HTML 4.01 transitional//en" >
In Tomcat with version number 7.0 or above. There is an error in using the quotes continuously. The workaround is as follows:
Tomcat-fix which must be escaped when used within the value error
2.static.html<! DOCTYPE html>
3.two.jsp<%@ page contenttype= "Text/html;charest=utf-8" language= "java"%><! DOCTYPE HTML PUBLIC "-//w3c//dtd HTML 4.01 transitional//en" ><br>this is A1=<%=request.getparameter ("A1")% ><br>this is A2=<%=request.getparameter ("A2")%><br><% out.println ("Hello from two.jsp"); %>
Code I uploaded to my resources. http://download.csdn.net/detail/svitter/7342523
Copyright notice: This article blog original article. Blogs, without consent, may not be reproduced.
Jsp_include directive and <jsp:include>