JSP页面不执行java代码,也不报错
<%@page import="java.util.ArrayList"%>
<%@ page language="java" contentType="text/html; charset=UTF-8"
pageEncoding="UTF-8"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>Insert title here</title>
</head>
<body>
当前在线用户人数${userNum} <br >
<%
ArrayList<entity.User> userList=(ArrayList<entity.User>)request.getServletContext().getAttribute("userList");
if(userList!=null){
for(int i = 0; i<userList.size();i++){
entity.User user = userList.get(i);
%>
IP:<%=user.getSessionip()%>,FirstTime:<%=user.getSessiontime() %>,Id:<%=user.getSessionIdstring() %><br >
<%}} %>
<%System.out.println("是不是无法显示?"); %>
</body>
</html>