title: Open p:confirmDialog on clicking of p:commandLink
body: <p>I am trying to open a PrimeFace ConfirmDialog on clicking of a PrimeFace CommandLink. But when the link is clicked the dialog is opened for a moment but vanishes instantly, I guess the page is being submitted. Here is the code:</p>
  
  <pre><code>&lt;p:commandLink value="Delete" onclick="confirmation.show()"  /&gt;
  
  &lt;p:confirmDialog message="Are you sure, you want to delete ?"  header="Initiating deleting process"  widgetVar="confirmation"&gt;  
      &lt;p:commandButton value="Yes Sure"  onclick="confirmation.hide()"  actionListener="#{adminCtrl.deleteUserById}" update="userData" &gt;
          &lt;f:attribute name="delete" value="#{user.userId}" /&gt;
      &lt;/p:commandButton&gt;  
      &lt;p:commandButton value="Not Yet" onclick="confirmation.hide()" type="button" /&gt;   
  &lt;/p:confirmDialog&gt;
  </code></pre>
  
  <p>How can I make the dialog to stay opened by this way?</p>
  
  <p>In the <a href="http://www.primefaces.org/showcase/ui/confirmDialog.jsf" rel="nofollow">PrimeFace ShowCase</a> the example deals with CommandButton and that was working but my requirement is to use CommandLink.</p>
  
  <p>Is it possible? Any pointer would be very helpful to me. </p>