|
From: Ken K. <kk...@kk...> - 2003-12-04 15:32:02
|
Giorgos, Check the *ContextLoaderServlet *Javadoc for an explanation. Ken Giorgos Zervas wrote: > Hi Darren, > > Actually I am doing what you suggested but the order was still wrong. > > Until I tried to use the <listener> tag instead of the <servlet> tag > to define the ContextLoaderListener. This fixed the problem although I > must admin that I don't quite understand why. > > Thanks, > Giorgos > > Darren Davison wrote: > >> >> >> >>> now here comes the problem... in the applicationSpecication.xml file >>> i have defined a simple DAO bean (<bean id="beanService"... etc>) >>> >>> and from the servlet-name.xml i refer to this bean in the definition >>> of my Controller: >>> >>> <bean id="myController" class="myControllerClass"> >>> <property name="myService"><ref bean="beanService"></property> >>> </bean> >>> >> >> >> >> the default name for the file is 'applicationContext.xml' rather than >> 'applicationSpecification.xml'. If you don't use the default name, >> you have >> to declare this in your web.xml as follows.. >> >> <web-app> >> ... >> <context-param> >> <param-name>contextConfigLocation</param-name> >> <param-value>/WEB-INF/applicationSpecification.xml</param-value> >> </context-param> >> ... >> </web-app> >> >> >> hth, >> Darren. >> >> >> -- >> Darren Davison >> Public Key: http://www.davison.uk.net/key.jsp >> >> >> ------------------------------------------------------- >> This SF.net email is sponsored by: IBM Linux Tutorials. >> Become an expert in LINUX or just sharpen your skills. Sign up for >> IBM's >> Free Linux Tutorials. Learn everything from the bash shell to sys >> admin. >> Click now! http://ads.osdn.com/?ad_id=1278&alloc_id=3371&op=click >> _______________________________________________ >> Springframework-developer mailing list >> Spr...@li... >> https://lists.sourceforge.net/lists/listinfo/springframework-developer >> >> > > > > > ------------------------------------------------------- > This SF.net email is sponsored by: IBM Linux Tutorials. > Become an expert in LINUX or just sharpen your skills. Sign up for IBM's > Free Linux Tutorials. Learn everything from the bash shell to sys admin. > Click now! http://ads.osdn.com/?ad_id=1278&alloc_id=3371&op=click > _______________________________________________ > Springframework-developer mailing list > Spr...@li... > https://lists.sourceforge.net/lists/listinfo/springframework-developer > > |