关于在jsp中的表达式

列子:

<%List<F_dd_tourist_info_markup> tourists = (List<F_dd_tourist_info_markup>) request.getAttribute("tourists");%>

</tr>
<%
for (F_dd_tourist_info_markup tourist : tourists) {
request.setAttribute("tourist", tourist);
%>
<tr id="tourist">
<td>
<img src="<%=basePath%>common/images/cross.png" alt="删除" title="删除"
onClick="deltourist(this)" style="cursor: pointer;"/>
</td>
<td width="17%">
<input type="hidden" name="rymem_id" value="${tourist.mem_id}"/>
<input type="text" class="tsui" name="fullname" value="${tourist.fullname}"/>
</td>
<td align="center">
<select name="idcardtypename" style="height: 25px;">
<%=Tool.dictionary("ZD_20027", application, "select", StringUtils.defaultIfEmpty(tourist.getIdcardtypename(), ""), false, "", "")%>
</select>
</td>
<td>
<input type="text" class="tsui" name="idcardcodes" value="${tourist.idcardcode}"/>
</td>

 

设置个request.setAttribute("tourist", tourist);下面就可以用${tourist.属性名}调用

相当于<%=%>

 

posted on 2016-09-03 23:52  牛奶糖13号  阅读(144)  评论(0编辑  收藏  举报

导航