• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Calling a servlet which contains so many different files

 
Pankaj Patro
Ranch Hand
Posts: 35
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi All,

How can I call a specific file which is in side of a servlet which contains so many different types of files.
My request is like this http://localhost:8080/ab.xyz
where ab.xyz is the file name with extention.

Please suggest me what steps should I take care to sucessed my application.

Advance ThankQ.
 
Paul Sturrock
Bartender
Posts: 10336
Eclipse IDE Hibernate Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

which is in side of a servlet which contains so many different types of files

Not sure what you mean by this. Can you explain?
 
Pankaj Patro
Ranch Hand
Posts: 35
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Paul,


Let assume that my application have a Controler Servlet, the jar file of this application contains so many files(including ab.xyz ,it may have different extention mean types) One of the file name is ab.xyz.

I wants to call that file like this request http://localhost:8080/ab.xyz

Insted of calling http://localhost:8080/jarfilename/ab.xyz
 
William Brogden
Author and all-around good cowpoke
Rancher
Posts: 13071
6
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Exactly what do you mean by "call that file"? Do you want the server to return it or execute it?
If you want the "Controller Servlet" to return that file, is your controller servlet configured to execute ALL requests to localhost:8080/
Bill
 
Yong Bakos
Greenhorn
Posts: 29
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Aryan, you should really make your life simple and use servlet-mappings in your web.xml. That way you can have

http://yourdomain.com/anypathyoulike

invoke any servlet you want.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic