On Tue, 28 Sep 2010 05:41:50 -0300, Lutz Hühnken
<lh.tapestry.l...@googlemail.com> wrote:
Dear Thiago,
Hi, Lutz!
now this - the lack of <form method=get> - is something that has been
puzzling me in Tapestry 5 for a long time. Why would you say using
"GET" is a bad idea?
Because all field values end up in the URL.
The use case I think of is a search field. You enter a search term,
submit the form, get the result. I think using a form with method=get
is the absolutely correct thing to do to achieve this.
I disagree 100%. Why not POST?
GET was always meant to be used in request that don't change the state of
the application (including database), while POST for requests that change
the state. In addition, Tapestry uses redirect-after-post by default (a
very good thing), so using GET would be useless anyway. Search Google for
"get vs post security" for some info and "redirect-after-post".
Of course I am willing to learn. What would be the "Tapestry way" of
implementing this?
Use Form and leave it using POST. If you want a bookmarkable URL, use the
page activation context instead. Tapestry and the form field components do
all the value handling for you.
--
Thiago H. de Paula Figueiredo
Independent Java, Apache Tapestry 5 and Hibernate consultant, developer,
and instructor
Owner, Ars Machina Tecnologia da Informação Ltda.
http://www.arsmachina.com.br
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org
For additional commands, e-mail: users-h...@tapestry.apache.org