2 Replies Latest reply on Dec 20, 2011 5:11 PM by Sharath Nagendra

    Syntax for linking to got to a different page

    Sharath Nagendra Newbie

      I am trying to figure out the syntax in a jsf/richfaces portlet using jboss portletbridge to have a link to take the user to the next page after setting some values as part of an action or a listener.


      The example in JBoss documentation is for a h:outputlink (Linking to Portlet/JSF Pages Using h:outputink) to go to a different page which works for me, but I have a case where I have a table with each row having a link to got to the next page and this would need some values set on the managed bean so that the next page can use this information.


      I have done this numerous times in a web app using commandlink, but when I try a command link it does not work for this purpose in a portlet. Here is what I have tried with commandlink:




      < h:commandLink action="#{bean.viewDetails}"  value ="View details.">


      <f:param name="javax.portlet.faces.ViewLink" value="true" />









      the action method returns the location of the next page, but the link is not taking me to the next page like the outputlink does.


      What would be the way to get this functionality working? any option to set values as part of outputlink or parameters for command link so that the link takes me to the next page or other options?