webtier@glassfish.java.net

Re: f:ajax and javascript events in JSF 2.0

From: <webtier_at_javadesktop.org>
Date: Tue, 02 Mar 2010 13:13:45 PST

Even though it's not quite as clean as being able to access the data via the returned ajax event object, there should be no reason why you can't embed the extra data in a hidden field passed back from the server. It would then be trivial for your jQuery code to locate and parse the contents of the hidden field. In fact, it seems like a pretty standard thing for JSF to do anyway, given the number of hidden input fields passed on any JSF page.

Alternatively you could always use the jQuery ajax calls (though obviously you lose the JSF functionality you might want) or perhaps you might be able to write your own custom action, or extend the existing f:ajax action, although that might be overkill for what you need.
[Message sent by forum member 'tacitust' (tacitus_at_yahoo.com)]

http://forums.java.net/jive/thread.jspa?messageID=389695