例如<context-param>
<param-name>log4jConfigLocation</param-name>
<param-value>/WEB-INF/log4j.properties</param-value>
</context-param>
请问我如何在jsp或者servlet中获取log4jConfigLocation的value?
问题点数:20、回复次数:1
Top
1 楼fangshao(方少)回复于 2006-03-29 23:03:26 得分 20
ServletContext
sc=this.getServletContext();
String
log4jConfigLocation=sc.getInitParameter("log4jConfigLocation");