You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tapestry.apache.org by "Doyle, Michael J" <mi...@gs.com> on 2003/05/01 01:21:56 UTC
Detecting submit
Thanks for all the previous help. Yes, I have been burned by outdate docs.
Hopefully this problem is straightfoward as well.
My form is submitted via an ordinary <input type="submit"/> button. My
understanding is that unless I specify otherwise, a page is its own
listener. Following the code in Vlib, it seems I should be able to handle
the query via the following:
Home.page
------------------
<component id="form" type="Form">
<binding name="listener" expression="listeners.query"/>
</component>
Home.java
--------------
public void query(IRequestCycle cycle)
{
log.info("Query received");
Visit visit = (Visit) getVisit();
visit.getData(_agreementType);
cycle.setPage("View");
}
However, query() is never invoked. The page simply refreshes (detach is
successfully called along the way).
What's the correct way of detecting and handling submission?
Thanks in advance,
- Mike