Warning: file_get_contents(/data/phpspider/zhask/data//catemap/7/jsf/5.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
编译JSF时的HTTP状态500_Jsf_Jakarta Ee_Tomcat - Fatal编程技术网

编译JSF时的HTTP状态500

编译JSF时的HTTP状态500,jsf,jakarta-ee,tomcat,Jsf,Jakarta Ee,Tomcat,在我的JSF应用程序中,当我访问url时,会出现HTTP Status 500错误。我创建什么web应用程序并不重要。此错误发生在我的所有应用程序上。我正在使用EclipseKepler、Tomcat7和JavaEE1.7 问题总是出现在相同的代码中,即f:视图行 type Exception report message An exception occurred processing JSP page /index.jsp at line 9 description The server

在我的JSF应用程序中,当我访问url时,会出现HTTP Status 500错误。我创建什么web应用程序并不重要。此错误发生在我的所有应用程序上。我正在使用EclipseKepler、Tomcat7和JavaEE1.7

问题总是出现在相同的代码中,即f:视图行

type Exception report

message An exception occurred processing JSP page /index.jsp at line 9

description The server encountered an internal error that prevented it from fulfilling this request.

exception

org.apache.jasper.JasperException: An exception occurred processing JSP page /index.jsp at line 9

6: <meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
7:  <title>Login Page</title>
8: </head>
9: <f:view>
10:     <center>
11:     Hello World
12:     </center>
类型异常报告
消息在第9行处理JSP页面/index.JSP时发生异常
说明服务器遇到内部错误,无法满足此请求。
例外
org.apache.jasper.jaspereException:在第9行处理JSP页面/index.JSP时发生异常
6: 
7:登录页面
8: 
9: 
10:     
11:你好,世界
12:     

您的JSP看起来有些奇怪-您是否在视图周围有一个
主体
标记,并且您指的是标记库

下面是一个工作示例:

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
    "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"
      xmlns:f="http://java.sun.com/jsf/core"
      xmlns:h="http://java.sun.com/jsf/html">
<body>
<f:view>
    <h:outputText value="Hello world!" />
</f:view>
</body>
</html>

(改编示例取自)