Warning: file_get_contents(/data/phpspider/zhask/data//catemap/2/jsf-2/2.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 2 访问我的JSF XHTML时未加载资源_Jsf 2_Primefaces_Tomcat7_Websphere 8 - Fatal编程技术网

Jsf 2 访问我的JSF XHTML时未加载资源

Jsf 2 访问我的JSF XHTML时未加载资源,jsf-2,primefaces,tomcat7,websphere-8,Jsf 2,Primefaces,Tomcat7,Websphere 8,我在WebSphere8.5上部署了我的应用程序,并尝试在浏览器中访问它。当加载页面时,显示混乱,当我查看页面源时,我看到以下带有“RES_NOT_FOUND”的内容 支持 当我在tomcat中部署相同的组件时,它工作得很好。以下是从tomcat截取的源代码视图 <html xmlns="http://www.w3.org/1999/xhtml"> <head> <link type="text/css" rel="stylesheet" hre

我在WebSphere8.5上部署了我的应用程序,并尝试在浏览器中访问它。当加载页面时,显示混乱,当我查看页面源时,我看到以下带有“RES_NOT_FOUND”的内容


支持
当我在tomcat中部署相同的组件时,它工作得很好。以下是从tomcat截取的源代码视图

<html xmlns="http://www.w3.org/1999/xhtml">
    <head>
    <link type="text/css" rel="stylesheet" href="/TryThisAppName/javax.faces.resource/theme.css.xhtml?ln=primefaces-aristo" />
    <link type="text/css" rel="stylesheet" href="/TryThisAppName/javax.faces.resource/primefaces.css.xhtml?ln=primefaces&amp;v=4.0" />
    <link type="text/css" rel="stylesheet" href="/TryThisAppName/javax.faces.resource/layout/layout.css.xhtml?ln=primefaces&amp;v=4.0" />
    <script type="text/javascript" src="/TryThisAppName/javax.faces.resource/jquery/jquery.js.xhtml?ln=primefaces&amp;v=4.0"></script>
    <script type="text/javascript" src="/TryThisAppName/javax.faces.resource/jquery/jquery-plugins.js.xhtml?ln=primefaces&amp;v=4.0"></script>
    <script type="text/javascript" src="/TryThisAppName/javax.faces.resource/primefaces.js.xhtml?ln=primefaces&amp;v=4.0"></script>
    <script type="text/javascript" src="/TryThisAppName/javax.faces.resource/layout/layout.js.xhtml?ln=primefaces&amp;v=4.0"></script>
    <title>SUPPORT</title>
    <!-- ncfb.is-asu 2012-02-13 ST02 replace  standard.stylesheets with custom -->
    <link href="/TryThisAppName/styles/mainstyle-en.css" rel="stylesheet" type="text/css" />
    <!-- ncfb.is-asu 2012-02-13 ST02 replace pt.styles with custom  -->
    <link href="/TryThisAppName/styles/mainstyle.css" rel="stylesheet" type="text/css" />
    <!-- ncfb.is-asu 2012-02-13 ST02 replace plumtree/portal/private/css/wcidojo.css with custom -->
    <link href="/TryThisAppName/styles/wcidojo.css" rel="stylesheet" type="text/css" />
    <link href="/TryThisAppName/styles/ncfbins-mainstyle.css" rel="stylesheet" type="text/css" />

    <!-- Intellect SEEC Custom Styles -->
    <link type="text/css" rel="stylesheet" href="/TryThisAppName/styles/customstyle.css" />

支持

有人能帮我解决这个问题吗?

我找到了解决问题的办法。在websphere中,无法从primefaces4.0.jar加载primefaces主题。因此,我提取了jar并获取了文件theme.css和primefaces.css,并将它们放在我的WebContent/styles文件夹中。这解决了我的问题。

显示您的xhtml文件。。。而且你必须给waaaaay更多的上下文,例如环境中的区别是什么,前面是否有代理(因为我看到“TryThis”和“TryThisAppName”),安全性是否到位等等。对不起,我将应用程序名称从实际名称改为类似“TryThis”的名称。在错误地执行此操作时,我在一个上下文中键入了“TryThisAppName”。它们都是相同的,除了一个是部署在websphere上时的输出,另一个是部署在tomcat上时的输出。我找到了解决我问题的办法。在websphere中,无法从primefaces4.0.jar加载primefaces主题和所有内容。因此,提取了jar并获取了文件theme.css和primefaces.css,并将它们放在我的WebContent/styles文件夹中。这解决了我的问题。奇怪的是,这是必需的…基本的jsf东西
<html xmlns="http://www.w3.org/1999/xhtml">
    <head>
    <link type="text/css" rel="stylesheet" href="/TryThisAppName/javax.faces.resource/theme.css.xhtml?ln=primefaces-aristo" />
    <link type="text/css" rel="stylesheet" href="/TryThisAppName/javax.faces.resource/primefaces.css.xhtml?ln=primefaces&amp;v=4.0" />
    <link type="text/css" rel="stylesheet" href="/TryThisAppName/javax.faces.resource/layout/layout.css.xhtml?ln=primefaces&amp;v=4.0" />
    <script type="text/javascript" src="/TryThisAppName/javax.faces.resource/jquery/jquery.js.xhtml?ln=primefaces&amp;v=4.0"></script>
    <script type="text/javascript" src="/TryThisAppName/javax.faces.resource/jquery/jquery-plugins.js.xhtml?ln=primefaces&amp;v=4.0"></script>
    <script type="text/javascript" src="/TryThisAppName/javax.faces.resource/primefaces.js.xhtml?ln=primefaces&amp;v=4.0"></script>
    <script type="text/javascript" src="/TryThisAppName/javax.faces.resource/layout/layout.js.xhtml?ln=primefaces&amp;v=4.0"></script>
    <title>SUPPORT</title>
    <!-- ncfb.is-asu 2012-02-13 ST02 replace  standard.stylesheets with custom -->
    <link href="/TryThisAppName/styles/mainstyle-en.css" rel="stylesheet" type="text/css" />
    <!-- ncfb.is-asu 2012-02-13 ST02 replace pt.styles with custom  -->
    <link href="/TryThisAppName/styles/mainstyle.css" rel="stylesheet" type="text/css" />
    <!-- ncfb.is-asu 2012-02-13 ST02 replace plumtree/portal/private/css/wcidojo.css with custom -->
    <link href="/TryThisAppName/styles/wcidojo.css" rel="stylesheet" type="text/css" />
    <link href="/TryThisAppName/styles/ncfbins-mainstyle.css" rel="stylesheet" type="text/css" />

    <!-- Intellect SEEC Custom Styles -->
    <link type="text/css" rel="stylesheet" href="/TryThisAppName/styles/customstyle.css" />