What is the difference between servlet config and servlet
context.

Answer Posted / gaurav chauhan

You can take it like as every servlet has the same
ServletContext but every servlet has its own ServletConfig.

For Example: If you want the name of your company and email
address appear in all pages of your web applications then
you use ServletContext.

Is This Answer Correct ?    6 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is the need of servlet filters?

531


What is Servlet API used for connecting database?

610


What is meant by a servlet?

594


What is cgi?

590


Why do we have servlet listeners?

593






Describe servlet?

571


Is it possible to have a constructor inside the servlet?

547


What's the architecture of a servlet package?

551


Write a program to show the functionality of servlets.

548


Tell us something about servletcontext interface.

616


What's the difference between servlets and applets?

552


What are the different methods involved in generic servlet?

550


Tell the new features added in servletrequest interface i.e. Servlet 2.4

565


Explain how does JSP handle run-time exceptions?

574


If a servlet is not properly initialized, what exception may be thrown?

618