title: primefaces command button/link not working
body: <p>Can anyone tel me why command button/link is not getting fired. This welcomePage() should be invoked on button press. I checked the managed property "value" is displaying on the execution, but button or link is not getting invoked.</p>
  
  <p>My <code>loginBean</code>:</p>
  
  <pre><code>import java.io.IOException;
  import java.io.Serializable;
  
  import javax.faces.application.FacesMessage;
  import javax.faces.bean.ManagedBean;
  import javax.faces.bean.ManagedProperty;
  import javax.faces.bean.RequestScoped;
  
  
  import javax.faces.context.FacesContext;
  import javax.faces.event.ActionEvent;
  
  @ManagedBean(name = "loginBean", eager = true)
  @RequestScoped
  
  public class loginBean implements Serializable {
  
      private String value = "This text shows, bean is working ";
  
      public String getValue() {
          return value;
      }
  
      public void setValue(String value) {
          this.value = value;
      }
  
      @ManagedProperty(value="#{name}")
      public static String name;
      public String getName() {  
          return name;  
      }  
  
      public void setName(String name) {  
          this.name = name;  
      }
  
      @ManagedProperty(value="#{password}")
      public static String password;
  
       public String getPassword() {  
              return password;  
          }  
  
          public void setPassword(String password) {  
              this.password = password;  
          }
  
  
       public String welcomePage()
          {
              System.out.println("welcome user according to user name");
  
                   return "customerGreeting.xhtml";
          }
  
  
  
  }
  </code></pre>
  
  <p>My <code>index.xhtml</code>:</p>
  
  <pre><code>&lt;?xml version='1.0' encoding='UTF-8' ?&gt;
  &lt;!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"&gt;
  &lt;html xmlns="http://www.w3.org/1999/xhtml"
        xmlns:p="http://primefaces.org/ui"
        xmlns:h="http://java.sun.com/jsf/html"
        xmlns:ui="http://java.sun.com/jsf/facelets"
        xmlns:f="http://java.sun.com/jsf/core"&gt;
  
  
      &lt;f:view contentType="text/html"&gt;
          &lt;h:head&gt;
              &lt;meta http-equiv="content-type" content="text/html; charset=UTF-8"/&gt;
              &lt;title&gt;Facelet Title&lt;/title&gt;
          &lt;/h:head&gt;
          &lt;h:body&gt;
          &lt;ui:composition&gt;
  
         &lt;div align ="center"&gt;  
  
  
         &lt;h:form id="form" align="center"&gt; 
          &lt;h:panelGrid id="panel" columns="2" &gt;
  
        &lt;f:facet name="header"&gt;
           &lt;h:outputText value="Login here:"/&gt;
        &lt;/f:facet&gt;
  
        &lt;h:outputLabel value="Username" /&gt;
        &lt;p:inputText id="name" value="#{loginBean.name}" /&gt;
  
        &lt;h:outputLabel value="Password" /&gt;
        &lt;p:password id="password" value="#{loginBean.password}" /&gt;
  
        &lt;f:facet name="footer"&gt;
           &lt;h:panelGroup style="display:block; text-align:center"&gt;
  
  
             &lt;p:commandButton id="submit1" value="Submit1" actionListener="#{loginBean.welcomePage}" /&gt;
  
             &lt;p:commandLink actionListener="#{loginBean.welcomePage}"&gt;
                  &lt;h:outputText id= "submit2" value="Submit2" /&gt;
              &lt;/p:commandLink&gt;
  
  
           &lt;/h:panelGroup&gt;
        &lt;/f:facet&gt;
  &lt;/h:panelGrid&gt;
  
         #{loginBean.value}
    &lt;/h:form&gt;
  
    &lt;/div&gt;
    &lt;/ui:composition&gt;
          &lt;/h:body&gt;
      &lt;/f:view&gt;
  &lt;/html&gt;
  </code></pre>
  
  <p>Any help ??</p>