Isn't it as simple as doing cycle.sendRedirect(url) in a form listener?
And then you could use the link factory to get the proper url:
Like this:

@InjectObject("engine-service:page")
public abstract IEngineService getPageService();

public void someFormEvent(IRequestCycle cycle) {
 ... // form actions.
 ILink link = getPageService().getLink(post, "SomePage");
 String url = link.getURL(anchor, true);
 cycle.sendRedirect(url);
}

It's not very intuitive but it can be done.
(and the redirect method used is the getRequestCycle() one).

--
Ing. Leonardo Quijano Vincenzi
DTQ Software
Web Application Design and Programming
http://www.dtqsoftware.com

James Sherwood wrote:
Yes and it works fine as long as you type that url in the browser or click on the link

What I am doing is using the beginResponse to do a
getRequestCycle().getRequestContext().redirect

to the url with the anchor in it that works if you just type it in the url. But i get a Page 'ConferenceSignUp#paymentmethod' not found in application namespace error.

Weird that no one seems to want to direct to an anchor after a form submit. Thought this would have been an easy one but is turning out to be a nightmare...

Thanks,
James
----- Original Message ----- From: "Onno Scheffers" <[EMAIL PROTECTED]>
To: "Tapestry users" <tapestry-user@jakarta.apache.org>
Sent: Tuesday, April 18, 2006 1:51 PM
Subject: Re: Forms in forms


James Sherwood schreef:

WOW, im really getting frustrated with anchors and Tapestry, it seems like they just will NOT get along.

Does anyone know how to send someone to a page with an anchor?

Well.. the components (like PageLink) have an anchor parameter that you can pass along. It should create the proper working URL for you.

Onno

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]





---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to