5.4. <a4j:commandButton>

The <a4j:commandButton> component is similar to the JavaServer Faces (JSF) <h:commandButton> component, but additionally includes Ajax support.
<a4j:commandButton>

Figure 5.1. <a4j:commandButton>

Note

Button controls are typically used to perform complete form submissions for data storing. As a consequence, the <a4j:commandButton> component has the execute="@form" setting by default. To limit rendering to a different scope, redefine the execute attribute.

5.4.1. Basic usage

The <a4j:commandButton> requires only the value attribute to function. Use the value attribute to specify the text of the button.
By default, the <a4j:commandButton> uses the click event instead of the submit event.

5.4.2. Reference data

  • component-type: org.richfaces.CommandButton
  • component-class: org.richfaces.component.UICommandButton
  • component-family: javax.faces.Command
  • renderer-type: org.richfaces.CommandButtonRenderer