📄 import.jsp
字号:
<%@taglib uri="jodd" prefix="jodd"%>
<!doctype html public "-//w3c//dtd html 4.0 transitional//en">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<title>Jodd ServerSide</title>
</head>
<body bgcolor="#FFFFFF">
<h1>import tag</h1>
<a href="import2.jsp">import2.jsp</a><br>
<a href="import3.jsp">import3.jsp</a><br><br>
request attributes are visible in included pages.<br>
example: request.setAttribute("ew", "<font color='red'>everywhere</font>");
<%request.setAttribute("ew", "<font color='red'>everywhere</font>");%>
<br><br>
this page has a request parameter <i>ward</i> set to <%=request.getParameter("ward")%>.<br>
It can be overridden in import tag, but NOT in the import param.<br>
<br>
Import params tags are not persistent by default.<br>
<hr>
<b>relative, w/ params:</b>
<jodd:import page="123.jsp?ward=NOFLY">
<jodd:param name="inline" value="<font color='blue'>inline</font>" persist="true"/>
<jodd:param name="noval">
noval: <%=request.getParameter("ward")%> <%=request.getAttribute("ew")%>
</jodd:param>
</jodd:import>
<hr>
<b>relative, no params:</b>
<jodd:import page="123.jsp"/>
<hr>
<b>relative:</b>
<jodd:import page="../tagiX.jsp?param=2"/>
<hr>
<b>absolute:</b>
<jodd:import page="/tagiX.jsp?param=2"/>
<br><br>
</body>
</html>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -