logo

JSF & PrimeFaces & Spring tutorial 17: PrimeFaces Confirm Dialog

Using Confirm Dialog component in PrimeFaces.

download result: https://app.box.com/s/2yo3c2y001qb1u18tgnq

index.xhtml:
<p:commandButton value="remove" action="#{checkListController.remove(check)}" 
		update=":checkTable, :messages">
	<p:confirm header="Confirmation" message="Are you sure?" icon="ui-icon-alert" />
</p:commandButton>
index.xhtml:
<h:form>
<p:confirmDialog global="true">
        <p:commandButton value="Yes" type="button" styleClass="ui-confirmdialog-yes" icon="ui-icon-check" />
        <p:commandButton value="No" type="button" styleClass="ui-confirmdialog-no" icon="ui-icon-close" />
</p:confirmDialog>
</h:form>

comments powered by Disqus

rss

Free online Java web application examples

Want to develop whole web applications which use database, security and more? See my github account, where are lot's of example projects:
github

Search