• Post Reply Bookmark Topic Watch Topic
  • New Topic

java jsp  RSS feed

 
Suresh Appagundi
Ranch Hand
Posts: 44
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
How can i make a call to servlet translated from jsp and access it.
thanks in advance.
 
Mark Spritzler
ranger
Sheriff
Posts: 17309
11
IntelliJ IDE Mac Spring
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Not sure what you are asking.
Are you asking this.
You have a JSP page, and you want something outside of this page to call a method you created in the JSP page?
Is this basically what you are asking?
Mark
 
Suresh Appagundi
Ranch Hand
Posts: 44
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
yes! you are right. When the jsp will be translated to servlet, how can i make a call to that particular servlet from simple ordinary java program.

Originally posted by Mark Spritzler:
Not sure what you are asking.
Are you asking this.
You have a JSP page, and you want something outside of this page to call a method you created in the JSP page?
Is this basically what you are asking?
Mark
 
Jeroen Wenting
Ranch Hand
Posts: 5093
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I don't think you can, they're kept separate from other classes.
The DO run in the same memoryspace as servlets in the same webapp, so you might be able to make direct calls to their methods from servlets and classes also in that webapp, but beware that the classnames of the JSPs are not guaranteed to stay the same over time (some servers I've seen added timestamps to the classname for example it seemed).
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!