RE: where I put my property files?
Mariano wrote: Where I have to put property files? I am using Tomcat and Struts. I suppose I have to put them in WEB-INF directory, but my application cannot find them. Maybe I have to add something in struts-config.xml Try putting it in WEB-INF/classes. It needs to be on the classpath. Take a look at the struts-example webapp to see where the .properties file is and how it's configured. -- Wendy Smoak Applications Systems Analyst, Sr. Arizona State University, PA, IRM - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: where I put my property files?
You have to put it/them under WEB-INF/classes Regards, Marco !-- ORIGINAL MESSAGE -- From: =?iso-8859-1?Q?Mariano_Garc=EDa?= [EMAIL PROTECTED] Hi all, Where I have to put property files? I am using Tomcat and Struts. I = suppose I have to put them in WEB-INF directory, but my application cannot find them. Maybe I have to add something in struts-config.xml Could you help me, please? - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: where I put my property files?
WEB-INF/classes ... WEB-INF/classes/resources say you have application.properties, configuration.properites in your web.xml servlet servlet-classorg.apache.struts.action.ActionServlet/servlet-class init-param param-nameapplication/param-name param-valueresources.application/param-value /init-param init-param param-nameconfiguration/param-name param-valueresources.configuration/param-value /init-param . /servlet it knows to look in WEB-INF/classes/resources/application.properties WEB-INF/classes/resources/configuration.properties - Original Message - From: Marco Tedone [EMAIL PROTECTED] To: Struts-user-list [EMAIL PROTECTED] Sent: Monday, September 15, 2003 2:29 PM Subject: Re: where I put my property files? You have to put it/them under WEB-INF/classes Regards, Marco !-- ORIGINAL MESSAGE -- From: =?iso-8859-1?Q?Mariano_Garc=EDa?= [EMAIL PROTECTED] Hi all, Where I have to put property files? I am using Tomcat and Struts. I = suppose I have to put them in WEB-INF directory, but my application cannot find them. Maybe I have to add something in struts-config.xml Could you help me, please? - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: where I put my property files?
The bit you're looking for is in web.xml, init-param param-nameapplication/param-name param-valueApplicationResources/param-value /init-param This means your ApplicationResources.properties is in: /WEB-INF/classes/ApplicationResources.properties were it the case that you wanted things different like /WEB-INF/classes/com.sparrow.myapp.ApplicationResources.properties then init-param param-nameapplication/param-name param-valuecom.sparrow.myapp.ApplicationResources/param-value /init-param Usually properties files would live with your source, so as far as putting them anywhere is concerned you'd usually have them where you source code is. ~/Projects/myapp/src/java/com/sparrow/myapp/ ApplicationResources.properties or ~/Projects/myapp/src/java/ApplicationResources.properties And they are copied with everything else when you build your project. Cheers Mark On Monday, September 15, 2003, at 04:56 PM, Mariano García wrote: Hi all, Where I have to put property files? I am using Tomcat and Struts. I suppose I have to put them in WEB-INF directory, but my application cannot find them. Maybe I have to add something in struts-config.xml Could you help me, please? _ Mariano García Ingeniero de Sistemas Optiva Media Viriato,25 - 28010 Madrid - España t. +34 91 445 96 95 m. +34 651 03 33 86 © This message is printed on 100% recycled electrons. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]