【问题标题】:Can I use multiple xhtml pages in the one xhtml page and how to access (references to them) those in managed bean class? [duplicate]我可以在一个 xhtml 页面中使用多个 xhtml 页面以及如何访问(引用它们)托管 bean 类中的那些页面吗? [复制]
【发布时间】:2015-01-16 21:06:17
【问题描述】:

1)如何在一个 xhtml 页面中包含多个 xhtml 页面
2)如何在托管 bean 类中获取对它们的引用

【问题讨论】:

标签: jsf-2


【解决方案1】:

你需要试试这个

 <ui:include src="/page.xhtml">
        <ui:param value="value" name="name" />
 </ui:include>

这里使用ui:param来传递参数。

【讨论】:

  • 但是如何访问 managedbean 类中 page.xhtml 的引用和内容
  • 应该是反过来,你应该在你的xhtml文件中访问属性并使用managedbean的功能。
猜你喜欢
  • 1970-01-01
  • 2020-12-14
  • 2012-09-15
  • 2014-06-21
  • 1970-01-01
  • 2012-12-12
  • 1970-01-01
  • 1970-01-01
  • 2014-04-04
相关资源
最近更新 更多