[Okta Webinar] Learn how to a build a cloud-first strategyRegister Now

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 251
  • Last Modified:

Jsp and servlet

how can a jsp  page use the objects instatiated by the servlet?????????
0
Maggieshah
Asked:
Maggieshah
  • 2
2 Solutions
 
CEHJCommented:
Get the servlet to save them in the session
0
 
Mayank SAssociate Director - Product EngineeringCommented:
Or preferably in the request,  using request.setAttribute () - if they are meant for only that request.
0
 
MaggieshahAuthor Commented:
How can integrate a servlet into a java program??
0
 
Mayank SAssociate Director - Product EngineeringCommented:
You can't run it directly. You need to run it in a servlet container like Tomcat:

http://tomcat.apache.org

You can of course, import other classes in it and use it.
0

Featured Post

Vote for the Most Valuable Expert

It’s time to recognize experts that go above and beyond with helpful solutions and engagement on site. Choose from the top experts in the Hall of Fame or on the right rail of your favorite topic page. Look for the blue “Nominate” button on their profile to vote.

  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now