ragi singh wrote:my question is if the context parameters are for the entire application then they should be declared in some tag at application scope and not web.xml .
web.xml is the perfect place to declare them.
also if we declare the context parameters in the web.xml of a particular servlet
web.xml declares
all servlets. And there is only one web.xml per application.
what if this servlet is not loaded at all then how will we ever b able to read the context parameters)
The context params have nothing at all to do with whether a servlet is loaded or not. Nothing at all. Any context params declared in the web.xml will always be available.