Take the 2-minute tour ×
Programmers Stack Exchange is a question and answer site for professional programmers interested in conceptual questions about software development. It's 100% free, no registration required.

We are initiating a Spring + Primefaces project and the first problem we have encountered concerns storing the XHTML pages into the WEB-INF folder.

When we use a faces form in a view located inside the WEB-INF folder, then the commandButton does not execute the managed bean method.

 <h:form id="loginForm">
    <p:commandButton action="#{LoginMgr.doLogin()}" value="Login"/>
 </h:form>

Our bean:

<bean id="LoginMgr" name="LoginMgr" class="com.tesipro.channelmanager.business.implemented.CMLoginManager">
</bean>

In fact we think the problem is that with JSF, the pages are rendered using a link to the same page as the action of the form, so if the page is located in WEB-INF it is not publicly accessible.

We know that having all our XHTML views in the web folder instead of WEB-INF actually solves the issue, but we would like to store that pages into WEB-INF.

share|improve this question

1 Answer 1

Does storing it in "app/WEB-INF/view" folder help? We do have several actions defined in XHTMLs in "app/WEB-INF/view" folder. Not invoking a spring bean from there, though, but calling a web-flow action.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.