Help; p:commandLink calls action but doesn't go to new page?

UI Components for JSF
Post Reply
rhume
Posts: 21
Joined: 07 Feb 2010, 07:30

04 Feb 2011, 18:37

JSF2 and GlassFish, PrimeFaces 2.1.

This works, showCreateProfile() method gets hit, and the method returns "profileForm" and the browser redirects to that page:

Code: Select all

<h:commandLink action="#{profileHandler.showCreateProfile}" value="#{msg.menu_createNewProfile}" />
However, this doesn't work, showCreateProfile() method get hits, and the method returns "profileForm" but the browser does not redirect to the page. I tried three different things with no luck:

Code: Select all

<p:commandLink action="#{profileHandler.showCreateProfile}" value="#{msg.menu_createNewProfile}" />

<p:commandLink action="#{profileHandler.showCreateProfile}" value="#{msg.menu_createNewProfile}" ajax="false" />

<p:commandLink action="#{profileHandler.showCreateProfile}" value="#{msg.menu_createNewProfile}" ajax="false" immediate="true"/>
Any ideas what I'm doing wrong?

Rob

max
Posts: 28
Joined: 17 Nov 2010, 15:55

07 Feb 2011, 05:15

if I want to redirect to user.xhtml page after doing a update() method. I would do:
<h:commandLink value="User Page" action="user" actionListener="#{controller.update}" ajax = "false">
So "user" is a xhtml page.

Post Reply

Return to “PrimeFaces”

  • Information
  • Who is online

    Users browsing this forum: No registered users and 30 guests