What is the difference between context parameters and initialization parameters in servlets?

  • Context parameters are set at the application level, while initialization parameters are specific to a servlet.
  • Context parameters are used for database connectivity, while initialization parameters are used for servlet configuration.
  • Initialization parameters are set at the application level, while context parameters are specific to a servlet.
  • Initialization parameters are used for database connectivity, while context parameters are used for servlet configuration.
Context parameters are set at the application level and are accessible to all servlets, while initialization parameters are specific to each servlet and are defined in the servlet's deployment descriptor (web.xml).
Add your answer
Loading...

Leave a comment

Your email address will not be published. Required fields are marked *