JAVA-JSP声明语句 

相关资料:

《21天学通Java Web开发》

 

结果总结:

1.<%! %>声明的变量为全局变量。

 

实例代码:

 1 <html>
 2 <head>
 3   <title>declarationsdemo</title>
 4 </head>
 5 <body>
 6   <%! int a=1; %>
 7   <%
 8     out.println("a="+a);
 9     a++; 
10   %>
11 </body>
12 </html>
View Code

 

相关文章:

  • 2021-12-22
  • 2021-08-10
  • 2021-10-16
  • 2022-12-23
  • 2022-12-23
  • 2021-09-21
  • 2021-08-19
猜你喜欢
  • 2022-12-23
  • 2022-12-23
  • 2021-09-09
  • 2022-12-23
  • 2021-06-18
  • 2021-08-03
相关资源
相似解决方案