<c:forEach var="变量" items="${bean.fwZlsqhqzzxx00s}" varStatus="s" >
<%
SysHelper.getCodeById(request,变量)
%>
</c:forEach>我在小脚本里面怎么拿到变量?
<%
SysHelper.getCodeById(request,变量)
%>
</c:forEach>我在小脚本里面怎么拿到变量?
调试欢乐多
request.getAttribute("变量");
%></c:forEach>
<%
request.getAttribute("变量");
%>
</c:set></c:forEach>
源码在此: if (itemId != null) {
if (getCurrent() == null)
pageContext.removeAttribute(itemId, PageContext.PAGE_SCOPE);
else
pageContext.setAttribute(itemId, getCurrent());
}所以取得方法为
pageContext.getAttribute("变量名", PageContext.PAGE_SCOPE);
或者
pageContext.getAttribute("变量名");
//不知道bean.fwZlsqhqzzxx00s是什么类型,看作List了
<% for(int i =0;i<bean.fwZlsqhqzzxx00s.size();i++){
String 变量 = bean.fwZlsqhqzzxx00s.get(i);
SysHelper.getCodeById(request,变量)
}
%>