aspose file tools*
The moose likes Servlets and the fly likes applicationScope Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of EJB 3 in Action this week in the EJB and other Java EE Technologies forum!
JavaRanch » Java Forums » Java » Servlets
Bookmark "applicationScope" Watch "applicationScope" New topic


Mike Tabak
Ranch Hand

Joined: Mar 31, 2012
Posts: 38
In my application web.xml file I have the following:


under the <jsp-config> tag

Shouldn't I be able to access this on a jsp as follows:

${applicationScope.initParam.custServEmail} ?

It works when I leave off the applicationScope, but I was testing the applicationScope and when I include it I get a null string.

Bear Bibeault
Author and ninkuma

Joined: Jan 10, 2002
Posts: 60050

Shouldn't I be able to access this on a jsp as follows:

No. Because initParam is it's own implicit object and is not in application scope.

[Asking smart questions] [Bear's FrontMan] [About Bear] [Books by Bear]
I agree. Here's the link:
subject: applicationScope
Similar Threads
EL and context-param???
retriving attributes using EL
JSP turning into Servlet
applicationScope in EL
variable doesn't increment