File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

How map the first servlet to second servlet

 
vijay kumar dahiya
Ranch Hand
Posts: 33
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello,
How I want map the second servlet by first servlet.
I have a Jsp file. In Jsp have a function which define in second servlet.
and Jsp file map with first servlet.How that fuction which define in second servlet will be execute.
Please Help me..
-Vijay.
 
Bear Bibeault
Author and ninkuma
Marshal
Pie
Posts: 64196
83
IntelliJ IDE Java jQuery Mac Mac OS X
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Originally posted by vijay kumar dahiya:
How I want map the second servlet by first servlet.
It's not clear what you mean by "map" here.

I have a Jsp file. In Jsp have a function which define in second servlet.
and Jsp file map with first servlet.How that fuction which define in second servlet will be execute.
From this, I am guessing that you have a method in a servlet that you want to access from a JSP?

If so, I'd advise against this approach. Firstly, modern JSPs should not have any Java code within them. Secondly, servlets shouldn't have general methods that are callable from other code. A better practice would be to take any such code and refactor out into general utility classes that can be called from anywhere.
 
I agree. Here's the link: http://aspose.com/file-tools
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic