用js获取jsp的java变量值



<html>


  </head>
  <body>


    <%
            int pageSize=5;
            session.setAttribute("pageSize",pageSize);
%>


    <script >
         var pageSize=${pageSize};


        alert(pageSize);
    </script>




  </body>
</html>

猜你喜欢

转载自blog.csdn.net/qq_38974073/article/details/78916968
今日推荐