0

I want to hide a richfaces ajax component when the component itself is clicked and render something else (an h:outputtext) in its place. Is this possible? If yes, how to do it?

  • 1
    Add rendering condition on component and re-render parent of it (+ other needed components). During event action change value for rendering condition of your component to false. – Vasil Lukach Mar 14 '16 at 14:19

1 Answers1

-1

You can update all the form

<rich:commandButton action="#{myBean.myAction}" reRender="formId" rendered="#{myBean.show}" />

Java code:

public void myAction() {
  show = !show;
}