struts标签
详情参见:添加链接描述
控制标签:
例如:
<%@ page language="java" contentType="text/html; charset=utf-8"
pageEncoding="utf-8"%>
<%@taglib prefix="s" uri="/struts-tags" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<title>property标签</title>
</head>
<body>
输出字符串:
<s:property value="'this is a string'"/><br/>
输出默认值:
<s:property value="" default="default_value"/><br/>
忽略HTML代码:
<s:property value="'<h2>www.w3school.com.cn</h2>'" escape="true"/><br/>
不忽略HTML代码:
<s:property value="'<h2>www.w3school.com.cn</h2>'" escape="false"/><br/>
</body>
</html>
输出结果:
结果:
示例:
结果展示: