File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes JSP and the fly likes url related Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of EJB 3 in Action this week in the EJB and other Java EE Technologies forum!
JavaRanch » Java Forums » Java » JSP
Bookmark "url related" Watch "url related" New topic
Author

url related

Anu Biswas
Greenhorn

Joined: Mar 22, 2007
Posts: 1
Hi!

I need to hide the name of the jsp file being accessed, from the URL being displayed in the browser.
I.e. if the initial page is being displayed as http://xyz.com/controller, and then I click some link or button and a new page say abc.jsp is being fetched, then I donot want http://xyz.com/abc.jsp to be displayed. Instead I need to continue showing http://xyz.com/controller, and this needs to be maintained everywhere.

Any help will be appreciated...Thanks in advance!
Bosun Bello
Ranch Hand

Joined: Nov 06, 2000
Posts: 1506
You can route the display of the jsp through the controller then, by having the controller handle the request and forward to the jsp. The URL will stay the same. Or you can also map that jsp to whatever URL you want via the deployment descriptor.


Bosun (SCJP, SCWCD)
So much trouble in the world -- Bob Marley
biny panackal
Ranch Hand

Joined: Apr 12, 2007
Posts: 72
if you need only to display the firt URL in the site. then you have to use <jsp:forward to go from one page to other. If you are using this the url keeps same and page changes


Biny Balan
binypanackal@gmail.com
Bear Bibeault
Author and ninkuma
Marshal

Joined: Jan 10, 2002
Posts: 60050
    
  65

Originally posted by biny panackal:
if you need only to display the firt URL in the site. then you have to use <jsp:forward to go from one page to other.

Forwarding only works within a single request. It cannot be used in place of links to traverse from page to page.


[Asking smart questions] [Bear's FrontMan] [About Bear] [Books by Bear]
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: url related
 
Similar Threads
calling JSP page in a Windows
Dynamic path configuration/resolving
URL in a IFRAME
alternative to query string
request.getRequestURI() problem