tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Karthik Nanjangude <karthik.nanjang...@xius-bcgi.com>
Subject RE: Hide JSP name using web.xml
Date Thu, 01 Apr 2010 05:12:51 GMT
Hi

I would want to request a jsp page from another page  as following

http://domain.com/folder1/abcd.jsp   to http://domain.com/folder2/xyz.jsp

Using Javascript / action

But I need both the JSP pages hidden in the URL ...... :(

With web.xml configurations should each configurations need to be done ?

I also have roughly 300+ similar pages across folder1 /folder 2
Request - Responding



With regards
Karthik




-----Original Message-----
From: Konstantin Kolinko [mailto:knst.kolinko@gmail.com]
Sent: Thursday, April 01, 2010 12:51 AM
To: Tomcat Users List
Subject: Re: Hide JSP name using web.xml

2010/3/31 Karthik Nanjangude <karthik.nanjangude@xius-bcgi.com>:
> Let us say I have
>
> http://domain.com/folder1/abcd.jsp  ==> http://domain.com/folder1/
> http://domain.com/folder2/xyz.jsp   ==> http://domain.com/folder2/
> (..)

You want to have requests to http://domain.com/folder1/ to be
processed by http://domain.com/folder1/abcd.jsp.  It can be done by
calling

ServletContext.getRequestDispatcher("/folder1/abcd.jsp").forward(request,
response)

The above call can be performed by a Servlet or by a Filter.
E.g. you can use http://tuckey.org/urlrewrite/  or write your own filter.

Best regards,
Konstantin Kolinko

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Mime
View raw message