How to include another XHTML in XHTML using JSF 2.0 Facelets?
问题 What is the most correct way to include another XHTML page in an XHTML page? I have been trying different ways, none of them are working. 回答1: <ui:include> Most basic way is <ui:include>. The included content must be placed inside <ui:composition>. Kickoff example of the master page /page.xhtml : <!DOCTYPE html> <html lang="en" xmlns="http://www.w3.org/1999/xhtml" xmlns:f="http://xmlns.jcp.org/jsf/core" xmlns:h="http://xmlns.jcp.org/jsf/html" xmlns:ui="http://xmlns.jcp.org/jsf/facelets"> <h