Expecting "jsp:param" standard action with "name" and "value" attributes错误
2011-04-02 09:34
501 查看
错误信息如下:
org.apache.jasper.JasperException: /index.jsp(14,0) Expecting "jsp:param" standard action with "name" and "value" attributes
org.apache.jasper.compiler.DefaultErrorHandler.jspError(DefaultErrorHandler.java:40)
org.apache.jasper.compiler.ErrorDispatcher.dispatch(ErrorDispatcher.java:407)
org.apache.jasper.compiler.ErrorDispatcher.jspError(ErrorDispatcher.java:88)
org.apache.jasper.compiler.Parser.parseParam(Parser.java:843)
org.apache.jasper.compiler.Parser.parseBody(Parser.java:1678)
org.apache.jasper.compiler.Parser.parseOptionalBody(Parser.java:1020)
org.apache.jasper.compiler.Parser.parseInclude(Parser.java:872)
org.apache.jasper.compiler.Parser.parseStandardAction(Parser.java:1134)
org.apache.jasper.compiler.Parser.parseElements(Parser.java:1461)
org.apache.jasper.compiler.Parser.parse(Parser.java:137)
org.apache.jasper.compiler.ParserController.doParse(ParserController.java:255)
org.apache.jasper.compiler.ParserController.parse(ParserController.java:103)
org.apache.jasper.compiler.Compiler.generateJava(Compiler.java:170)
org.apache.jasper.compiler.Compiler.compile(Compiler.java:332)
org.apache.jasper.compiler.Compiler.compile(Compiler.java:312)
org.apache.jasper.compiler.Compiler.compile(Compiler.java:299)
org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:586)
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:317)
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:342)
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:267)
javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
html文件:
<%@ page language="java" contentType="text/html; charset=UTF-8"
pageEncoding="UTF-8"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/functions" prefix="fn"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/fmt" prefix="fmt" %>
<!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>ss</title>
</head>
<body>
<jsp:include page="include/header.jsp">
</jsp:include>
dd
</body>
</html>
原因:当<jsp:include>标签没有参数时,<jsp:include page="include/header.jsp">的配对标签</jsp:include>不能换行。修改后html文件如下:
<%@ page language="java" contentType="text/html; charset=UTF-8"
pageEncoding="UTF-8"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/functions" prefix="fn"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/fmt" prefix="fmt" %>
<!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>ss</title>
</head>
<body>
<jsp:include page="include/header.jsp"></jsp:include><!-- 此处必须在同一行,不能换行 -->
dd
</body>
</html>
org.apache.jasper.JasperException: /index.jsp(14,0) Expecting "jsp:param" standard action with "name" and "value" attributes
org.apache.jasper.compiler.DefaultErrorHandler.jspError(DefaultErrorHandler.java:40)
org.apache.jasper.compiler.ErrorDispatcher.dispatch(ErrorDispatcher.java:407)
org.apache.jasper.compiler.ErrorDispatcher.jspError(ErrorDispatcher.java:88)
org.apache.jasper.compiler.Parser.parseParam(Parser.java:843)
org.apache.jasper.compiler.Parser.parseBody(Parser.java:1678)
org.apache.jasper.compiler.Parser.parseOptionalBody(Parser.java:1020)
org.apache.jasper.compiler.Parser.parseInclude(Parser.java:872)
org.apache.jasper.compiler.Parser.parseStandardAction(Parser.java:1134)
org.apache.jasper.compiler.Parser.parseElements(Parser.java:1461)
org.apache.jasper.compiler.Parser.parse(Parser.java:137)
org.apache.jasper.compiler.ParserController.doParse(ParserController.java:255)
org.apache.jasper.compiler.ParserController.parse(ParserController.java:103)
org.apache.jasper.compiler.Compiler.generateJava(Compiler.java:170)
org.apache.jasper.compiler.Compiler.compile(Compiler.java:332)
org.apache.jasper.compiler.Compiler.compile(Compiler.java:312)
org.apache.jasper.compiler.Compiler.compile(Compiler.java:299)
org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:586)
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:317)
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:342)
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:267)
javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
html文件:
<%@ page language="java" contentType="text/html; charset=UTF-8"
pageEncoding="UTF-8"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/functions" prefix="fn"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/fmt" prefix="fmt" %>
<!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>ss</title>
</head>
<body>
<jsp:include page="include/header.jsp">
</jsp:include>
dd
</body>
</html>
原因:当<jsp:include>标签没有参数时,<jsp:include page="include/header.jsp">的配对标签</jsp:include>不能换行。修改后html文件如下:
<%@ page language="java" contentType="text/html; charset=UTF-8"
pageEncoding="UTF-8"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/functions" prefix="fn"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/fmt" prefix="fmt" %>
<!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>ss</title>
</head>
<body>
<jsp:include page="include/header.jsp"></jsp:include><!-- 此处必须在同一行,不能换行 -->
dd
</body>
</html>
相关文章推荐
- Expecting "jsp:param" standard action with "name" and "value" attributes错误
- /doreg.jsp (line: 11, column: 0) Expecting "jsp:param" standard action with "name" and "value" attributes 错误解决办法
- Expecting "jsp:param" standard action with "name" and "value" attributes
- Expecting "jsp:param" standard action with "name" and "value" attributes错误
- Expecting "jsp:param" standard action with "name" and "value" attributes错误
- Expecting "jsp:param" standard action with "name" and "value" attributes
- Expecting "jsp:param" standard action with "name" and "value" attributes错误
- jsp报错:Expecting "jsp:param" standard action with "name" and "value" attributes
- Expecting "jsp:param" standard action with "name" and "value" attributes
- Expecting "jsp:param" standard action with "name" and "value" attributes
- Expecting "jsp:param" standard action with "name" and "value" attributes
- Expecting "jsp:param" standard action with "name" and "value" attributes解决方案
- jsp(108,0) Expecting "jsp:param" standard action with "name" and "value" attributes
- org.apache.jasper.JasperException: Expecting "jsp:param" standard action with "name" and "value" attributes
- JSP Expecting "jsp:param" standard action with "name" and "value" attributes
- JSP - Expecting “jsp:param” standard action with “name” and “value” attributes
- Expecting "jsp:param" standard action with "name" and "value" attribu
- HTTP Status 500 - /dologin.jsp (line: 27, column: 3) Expecting "jsp:param" standard action with "nam
- <a href="<s:url action="navDel" ><s:param name="id" value="pid"/></s:url>"> 删除 </a>
- jpivot : javax.servlet.jsp.JspException: An error occurred while evaluating custom action attribute "test" with value "${query01