On Sat, 30 Jan 2010 19:58:34 -0200, Jan Jirout <jir...@coroptis.com> wrote:
Hi All,
Hi!
I have strange problem with URL rewriting. I'm changing path name in
URLRewriterRule. In following way:
public Request process(Request request, URLRewriteContext context)
{
return new SimpleRequestWrapper(request, "somePath");
}
The above rule rewrites *all* URLs to "somePath", losing any context or
query parameters. You should use string manipulation to extract the
original page name and then replace it with the new page name.
If a request to "/original/1 arrives", your should rewrite it to "/new/1".
You can use path.replace("/original/", "/new/") to do that, for example.
--
Thiago H. de Paula Figueiredo
Independent Java, Apache Tapestry 5 and Hibernate consultant, developer,
and instructor
Owner, software architect and developer, 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