在Glassfish v3中使用JNDI配置/查找为JavaServer Faces设置项目阶段 [英] Set project stage for JavaServer Faces with JNDI configuration/lookup in Glassfish v3
问题描述
我将舞台属性设置为 ,然后将舞台属性设置为开发阶段,但我的申请总是收到生产阶段。
我在Windows系统上使用GlassFish Server Open Source Edition 3.1(版本43)。
为了在JSF页面中呈现项目阶段,我使用下面的代码:
< h:outputText value =Stage:#{facesContext.application.projectStage}/>
在应用程序中使用项目阶段还有其他必要吗?该应用程序没有web.xml文件。
一切正常,但不是 stage = Development
,请使用 value = Development
,
即用值替换
在属性名称字段中。阶段
值
I'm trying to set the project stage for JavaServer Faces in a GlassFish application server v3 with a JNDI property.
I set the stage property to Development stage, but my application received always the Production stage.
I use GlassFish Server Open Source Edition 3.1 (build 43) on a windows system.
For rendering the project stage in the JSF page I use this:
<h:outputText value="Stage:#{facesContext.application.projectStage}"/>
Is anything else necessary to use the project stage in an application? The application has no web.xml file.
Everything is correct, but instead of stage=Development
, use value = Development
,
i.e. replace stage
with value
in the property name field.
这篇关于在Glassfish v3中使用JNDI配置/查找为JavaServer Faces设置项目阶段的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!