In an Ajax request, returning a JSONObject is completely appropriate return
value from a component event that expects a page navigation result.  This
will mix-and-match well with AjaxResponseRenderer (under 5.3 and 5.4); that
is, you can return a JSONObject and Tapestry will add to it the keys for
zone updates and page initializations related to rendering Blocks and Zones.

Under 5.4, it's a bit neater, with the partial page render response values
buried down a level under a "_tapestry" key.


On Fri, Nov 9, 2012 at 9:09 AM, Lance Java <lance.j...@googlemail.com>wrote:

> Tapestry does NOT accept JSONObject as a return value from a component
> event.
> If you want to make a JSONObject available in your javascript, you should
> use AjaxResponseRenderer.
>
> http://tawus.wordpress.com/2011/10/01/tapestry-5-3-new-features-part-2/
>
>
>
> --
> View this message in context:
> http://tapestry.1045711.n5.nabble.com/Howto-render-a-block-and-put-it-into-a-JSON-reply-tp5486823p5717885.html
> Sent from the Tapestry - User mailing list archive at Nabble.com.
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org
> For additional commands, e-mail: users-h...@tapestry.apache.org
>
>


-- 
Howard M. Lewis Ship

Creator of Apache Tapestry

The source for Tapestry training, mentoring and support. Contact me to
learn how I can get you up and productive in Tapestry fast!

(971) 678-5210
http://howardlewisship.com

Reply via email to