Exams Attended

Mock Exams

Make Homepage

Bookmark this page

Subscribe Email Address

JSF Interview Questions and Answers

Ques. How to add context path to URL for outputLink?
Ans. Current JSF implementation does not add the context path for outputLink if the defined path starts with '/'. To correct this problem use #{facesContext.externalContext.requestContextPath} prefix at the beginning of the outputLink value attribute. For For Example:
<h:outputLink value=”#{facesContext.externalContext.requestContextPath}/myPage.faces”> 



Is it helpful? Yes No

Most helpful rated by users:

©2021 WithoutBook