What is the difference between servlet config and servlet
context.

Answer Posted / vijay kaarmani

Both ServletConfig and ServletContext are configuration objects used by servlet container to initialize various init parameters for a web application. However they differ in terms of the scope and availability of init parameters defined by both of them.

Please see http://javashiksha.com/servlet-jsp/difference-between-servlet-config-and-servlet-context.html for more details

Is This Answer Correct ?    0 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Is dispatcher servlet a singleton?

542


If my browser does not support cookie, and my server sends a cookie instance what will happen?

646


Explain the war file?

606


What is the capacity the doget can send to the server?

568


Can we use threads in Servlets?

648






How to make sure a servlet is loaded at the application startup?

549


Can filter be used as request or response?

540


What is difference between get and post method?

571


Is tomcat a servlet container?

570


What is meant by session? Tell me something about httpsession class?

596


What is load-on-startup in servlet?

580


What is the difference between get and post methods?

599


What are the exceptions thrown by servlets? Why?

618


How does java thread pool work?

542


What is the life-cycle of servlets?

629