Experience points talk about the statement in JSP.

zhaozj2021-02-11  195

Declaration in JSP: There are two ways in jsp: one is <% intcount = 0%>, the other is <%! Intcount = 0%>, now talk about the second .1, test conditions : Suppose there are two page TEST1.JSP and TEST2.JSP have the following code: <%! Intcount = 0%> <% intcount = 1; Out.print ("" INTCOUNT "people enter this page!"); ") %> 2, Test Environment: JRUN3 JDK1.23, Test Results: · This intcount As long as it is in the same page, it is equivalent to an Application in an ASP, and each user shares this variable, and initializes Intcount = 0 is only in the first When a user logs in. But different pages do not affect each other.

转载请注明原文地址:https://www.9cbs.com/read-4292.html

New Post(0)