Warning: file_get_contents(/data/phpspider/zhask/data//catemap/6/eclipse/9.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
Java JSF、JBOSS的显示不正确_Java_Eclipse - Fatal编程技术网

Java JSF、JBOSS的显示不正确

Java JSF、JBOSS的显示不正确,java,eclipse,Java,Eclipse,我在JBoss6、Eclipse、JSF MOJARRA中遇到了这个奇怪的问题 这是我的index.xhtml: <!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:h="http

我在JBoss6、Eclipse、JSF MOJARRA中遇到了这个奇怪的问题

这是我的index.xhtml:

<!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:h="http://java.sun.com/jsf/html"
      xmlns:f="http://java.sun.com/jsf/core"
     >

    <!-- 
        Replace path to template, title, header and body
        with actual data.
     -->
    <h:head>
        <title>JSF 2.0 Hello World</title>
    </h:head>
    <h:body>
        <h3>JSF 2.0 Hello World Example - hello.xhtml</h3>
        <h:form>
           <h:inputText value="#{helloBean.name}"></h:inputText>
           <h:commandButton value="Welcome Me" action="welcome"></h:commandButton>
        </h:form>

    </h:body>

</html>

JSF2.0 Hello World
JSF2.0 Hello World示例-Hello.xhtml
在执行过程中,我只有页面的标题,没有输入文本,没有按钮。
请帮帮我

看起来您的页面无法解析。您应该检查faces-config.xml是否有这行代码,并且您的lib必须有jsf-facelets.jar

 < view-handler>com.sun.facelets.FaceletViewHandler< /view-handler>