This post has been written on May 2005.
I've read the ILink approach an Howard's blog dated of february 2006 ...
( http://howardlewisship.com/tapestry-javaforge/tapestry-flash/index.html )
Are you sure the redirection is the good solution ? Is the redirection
really send a redirect reponse to the client browser ? How could i pass
parameters to the destination page in the redirect approach ?
Stephane
James Carman a écrit :
In order to redirect, you have to throw a RedirectException. Have you read
this:
http://www.tapestryforums.com/-vp14687.html
-----Original Message-----
From: Stephane Decleire [mailto:[EMAIL PROTECTED]
Sent: Tuesday, June 20, 2006 8:29 AM
To: users@tapestry.apache.org
Subject: redirect-after-post pattern
Hi,
I've tried to implement redirect-after-post pattern in Tapestry4 without
success ...
I've read that the way to send a redirect reponse to the client web
browser is to return an ILink from the form listener method like this :
@InjectObject("engine-service:page")
public abstract IEngineService getPageService();
public ILink doFormSubmit()
{
// ...
return getPageService().getLink(false, getPageName());
}
But I can't return an ILink in my listener if an error is found during the
validation of the form :
IValidationDelegate delegate = getValidationDelegate();
if (delegate.getHasErrors())
return;
Did i miss something ? What's the trick ??
Thanks in advance for any clue.
--
Stéphane Decleire
05 56 57 99 20
06 63 78 69 06