p:commandButton ajax=false" and p:confirm

UI Components for JSF
Post Reply
Posts: 1
Joined: 14 Mar 2014, 15:50

14 Mar 2014, 16:47


I've notice something regarding to global confirmDialog used with commandlink and commandButton.

if the the commandButton has the property ajax="false", the confirm dialog is not shown.

The commandLink works as expected and both of them with ajax="true" as well.

Code: Select all

<p:commandButton ajax="false" value="" action="#{myBean.myAction}"  id="buttonNotOK">			
		<p:confirm icon="ui-icon-alert"  header="not ok" message="won't show"/>

<p:commandLink ajax="false" value="" action="#{myBean.myAction}"  id="buttonOK">			
		<p:confirm icon="ui-icon-alert"  header="ok" message="this works"/>

	<p:confirmDialog global="true">  
		<p:commandButton value="do it" styleClass="ui-confirmdialog-yes" icon="ui-icon-check"/>
		<p:commandButton value="cancel" styleClass="ui-confirmdialog-no"  icon="ui-icon-close"/>    
So it this a bug? there is no javascript generated for the onclick method.

Thanks in advance,
PrimeFaces 4.0 | Mojarra 2.1.19 | JBoss EAP 6.2 | JBoss JPP 6.1

Posts: 6
Joined: 21 Oct 2013, 14:46

09 Dec 2016, 16:14

Hi everyone,

I am also seeing this issue as well. When I have a confirmDialog with a commandButton triggerring it, if the ajax is set to "false". The confirmDialog is shown but when clicking the "Yes" button the action from the commandButton does not fire. Does anyone have a fix for this?

Posts: 6
Joined: 21 Oct 2013, 14:46

10 Dec 2016, 14:55

Does anyone know if this is resolved in 6.0? We are using 5.2 now.

PrimeFaces Core Developer
Posts: 3769
Joined: 03 Dec 2010, 14:11
Location: Bavaria, DE

11 Dec 2016, 00:51

Just try 6.0 ;)
Thomas Andraschko

PrimeFaces | PrimeFaces Extensions

Apache Member | OpenWebBeans, DeltaSpike, MyFaces, BVal, TomEE

Sponsor me: https://github.com/sponsors/tandraschko
Blog: http://tandraschko.blogspot.de/
Twitter: https://twitter.com/TAndraschko

Post Reply

Return to “PrimeFaces”

  • Information
  • Who is online

    Users browsing this forum: No registered users and 7 guests