title: Primefaces p:remoteCommand parameter always null
body: <p>I am trying to pass a parameters with </p>
  
  <blockquote>
    <p>p:remoteCommand</p>
  </blockquote>
  
  <p>Unfortunately when I retrieve the paramer in my bean method I always get null.</p>
  
  <p>Is there anything wrong with my code?</p>
  
  <p>Here is my page code:</p>
  
  <pre><code>&lt;a href="#" onclick="rc([{'d':'01'}])"&gt;01&lt;/a&gt;
  
  &lt;p:remoteCommand name="rc" update=":myform:messages" actionListener="#{mybean.changedaybar}" /&gt;
  </code></pre>
  
  <p>and this is the bean method:</p>
  
  <pre><code>public void changedaybar() {
              Map&lt;String, String&gt; params = FacesContext.getCurrentInstance().getExternalContext().getRequestParameterMap();
              String param = params.get("d");
  
              FacesContext.getCurrentInstance().addMessage(null, new FacesMessage(FacesMessage.SEVERITY_INFO, "Executed"+param, "Using RemoteCommand."));
      }
  </code></pre>