在页面中加入下面的代码:
<%
Object obj = application.getAttribute("count");
if(obj==null){
Integer count = 1;
application.setAttribute("count",count);
}else{
Integer count = (Integer)obj;
count++;
application.setAttribute("count",count);
}
%>
在引用出加入下面代码:
<%=obj.toString()%>