Home » Primefaces Ajax Listener

Primefaces Ajax Listener

by Online Tutorials Library

PrimeFaces Ajax Listener

This attribute is used to call Java method by using an Ajax request. It is an attribute of <a:ajax> component.

Here, we are creating an example that calls a method from ManagedBean. It includes the following files and code.

JSF File

// ajax-listener.xhtml

Managed Bean

// ListenerBean.java

Output:

PrimeFaces Listener 1

It will call Java method that converts input value into uppercase.

PrimeFaces Listener 2

You may also like