I'm not 100% sure but I think returning a block only works with Zones. In all other cases, the rules
as described here http://tapestry.apache.org/tapestry5/guide/pagenav.html apply.
Cheers,
Uli
dsarosi schrieb:
I'm trying to render a block instead of the page when using an ajax call.
This way, I can have a low-bandwidth and a high-bandwith (AJAX enabled
site).
@Inject
@Property
private Block _content;
@OnEvent("activate")
Object activate()
{
if (req.isXHR())
return _content
Object page = validateUserSession();
retrieveMailSetting();
return page;
}
However, when I make the ajax call, i get the following error;
A component event handler
method returned the value Block[content within mail/Compose, at
context:mail/Compose.tml, line 2, column
25]. Return type org.apache.tapestry5.internal.structure.BlockImpl can not
be handled. Configured return
types are java.lang.Class, java.lang.String, java.net.URL,
org.apache.tapestry5.Link, org.apache.tapestry5
.StreamResponse, org.apache.tapestry5.runtime.Component.
Any suggestions?
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org
For additional commands, e-mail: users-h...@tapestry.apache.org