This action refers to the current page contains one or more JSP pages or HTML files, syntax: <jsp:include file= ". /jsp/login.jsp "flush=" true "/>
Where file is the relative path where the files are loaded, and the Flush property is set to True, the load page is automatically refreshed. If you need to pass parameters when loading a file or Web page, the syntax format is as follows:
<jsp:include file= ". /jsp/login.jsp "flush=" true "/> <jsp:param name=" username "value=" admin "/> <jsp:param naem=" Userpass "value=" 123456 "/></jsp:include>
The source code for the usinglogin.jsp file is:
<%@ page pageencoding= "utf-8"%><%@ page contenttype= "text/html; Charset=utf-8 "%><%@ include file="./login.html "%>
The source code for the login.html file is:
Put two files in the same directory, start Tomcat, enter in the browser: http://localhost:8080/jsp/006/UsingLogin.jsp, the browser page appears as follows:
At this point, Java Learning -037-javaweb_006-JSP Action logo-include a smooth end, I hope this article can give beginners javaweb you a reference.
Finally, very grateful to the pro-stop, I hope this article can be pro helpful. Warmly welcome the kiss to discuss together and progress together. Thank you so much! ^_^
Java Learning -037-javaweb_006--JSP action ID-Include