Title:Test.jsp
discription:
@Copyright:
@Company:
@autor:firefly
@version:1.0
@time:2013.1.2
<%@ page import="bean.*" %>
<%//导入bean包中的,相关的java类
<%--
<% response.sendRedirect("../servlet/ShowRs"); %>
<% CounterBean cb = new CounterBean(); %>
<font color="red" size="5">
<%=cb.getCount()%>
</font>
--%>
oooooo
<jsp:useBean id="cb" class="bean.CounterBean">
<%//运用bean包中的CouterBena.java, 创建一个实例的名字是cb%>
</jsp:useBean>
<jsp:setProperty name="cb" property="count" value="23"/> <%-- cb.setCount(Integer.parseInt("23")) --%>
<jsp:getProperty name="cb" property="count"/> <%-- out.print(cb.getCount()) --%>