org.apache.jasper.JasperException: /WEB-INF/jsps/index.jsp(9,26) #{...} is not allowed in template t

来源:互联网 发布:linux 目录函数 编辑:程序博客网 时间:2024/06/14 04:54

访问页面的时候发生如下错误:

org.apache.jasper.JasperException: /WEB-INF/jsps/index.jsp(9,26) #{...} is not allowed in template text

<%@ page language="java" import="java.util.*" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%><!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"><html>  <head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"><title>Insert title here</title>  </head>  <!-- mybatis里面一般获取参数使用#{}这种形式,而在jsp中则是${}这种形式 -->  <body>    This is my JSP page.<br>    </body></html>

其实错误就是这里的:

<!-- mybatis里面一般获取参数使用#{}这种形式,而在jsp中则是${}这种形式 -->



去掉这里的注释就可以了。

0 0
原创粉丝点击