----------------------------------------------------------------
BEFORE YOU POST, search the faq at <http://java.apache.org/faq/>
WHEN YOU POST, include all relevant version numbers, log files,
and configuration files.  Don't make us guess your problem!!!
----------------------------------------------------------------

Hi,
Since Jserv is started by apache, ur jvm's user.dir is apache root. 
If you want to place ur .properties file in servlet directory, the only
thing u need to pass to ur servlet might be the location of the properties
file.
That is,
.properties file - in ur servlet directory
zone.properties - for this servlet , the init parameter would be path to the
.properties file

Then in ur servlet's init method, read this init property and u can read the
properties file in ur servlet directory.

I hope this is what u r looking for and its clear, if not i'll explain once
again.
HTH
Sudhi

> -----Original Message-----
> From: Manzoor Patel [mailto:[EMAIL PROTECTED]]
> Sent: Monday, February 05, 2001 8:55 AM
> To: Java Apache Users
> Subject: Re: how to make Apache Look for properties file in Servlets
> directory?
> 
> 
> ----------------------------------------------------------------
> BEFORE YOU POST, search the faq at <http://java.apache.org/faq/>
> WHEN YOU POST, include all relevant version numbers, log files,
> and configuration files.  Don't make us guess your problem!!!
> ----------------------------------------------------------------
> 
> Hello Kenneth and Paul Maguire,
>                         In fact I dont want to create a 
> servlet zone.Let me
> put my problem like this...
> I have a webApplication the servelet connect to the data 
> base, mail server..
> and I have put the database URL,Driver,Mailserver IP etc in a 
> properties
> file.Now I have this porperties file in Apache root directory 
> ie F:\Apache
> and every thing is working fine. Now  if I put this 
> properties file in the
> servelets derectory ( the Apache defalut servelts zone) it is 
> not reachable.
> I want to put this in the servlet directory so that I can 
> make a JAR file of
> all my code including the properties file...so that it will 
> could be put in
> servelets derectory by any one & could the application could be used.
> Please let me know how can I go about it. I am new to Apache 
> please dont
> mind if I am asking silly questions.
> 
> 
> Thanks.
> Manzoor
> 
> ----- Original Message -----
> From: "Chris Mangiapane" <[EMAIL PROTECTED]>
> To: "Java Apache Users" <[EMAIL PROTECTED]>
> Sent: Friday, February 02, 2001 7:51 PM
> Subject: Re: how to make Apache Look for properties file in Servlets
> directory?
> 
> 
> > ----------------------------------------------------------------
> > BEFORE YOU POST, search the faq at <http://java.apache.org/faq/>
> > WHEN YOU POST, include all relevant version numbers, log files,
> > and configuration files.  Don't make us guess your problem!!!
> > ----------------------------------------------------------------
> >
> > Manzoor Patel wrote:
> > >
> > > Hello,
> > >         I have a properties file, how can I make the 
> Apache look for
> > > the properties file in the servlets directory?
> > > By default the Apache is looking for the my properties file in the
> > > Apache directory.
> > >
> > > Many Thanks
> > > Manzoor
> >
> >
> > My setup is as follows:
> > Apache 1.3.11
> > Apache JServ 1.1
> > OS: RedHat LInux 5.2
> >
> > First look in httpd.conf file for the Include directive
> > which specifies the path to the jserv.conf file.
> > Mine is :
> > Include /usr/local/apache/conf/jserv/jserv.conf
> >
> > Next look in the jserv.conf file
> > for the directive ApJServProperties
> > this specifies the path to the properties file.
> >
> > Why would you want to put the properties file in your
> > servlets directory?
> >
> > Also, try to include relevant information like
> > Operating System, version of Apache, version
> > of JServ, JDK, etc.
> >
> > Chris Mangiapane
> > [EMAIL PROTECTED]
> >
> >
> > --
> > --------------------------------------------------------------
> > Please read the FAQ! <http://java.apache.org/faq/>
> > To subscribe:        [EMAIL PROTECTED]
> > To unsubscribe:      [EMAIL PROTECTED]
> > Search Archives:
> > 
> <http://www.mail-archive.com/java-apache-users%40list.working-
dogs.com/>
> Problems?:           [EMAIL PROTECTED]


--
--------------------------------------------------------------
Please read the FAQ! <http://java.apache.org/faq/>
To subscribe:        [EMAIL PROTECTED]
To unsubscribe:      [EMAIL PROTECTED]
Search Archives: 
<http://www.mail-archive.com/java-apache-users%40list.working-dogs.com/>
Problems?:           [EMAIL PROTECTED]


--
--------------------------------------------------------------
Please read the FAQ! <http://java.apache.org/faq/>
To subscribe:        [EMAIL PROTECTED]
To unsubscribe:      [EMAIL PROTECTED]
Search Archives: 
<http://www.mail-archive.com/java-apache-users%40list.working-dogs.com/>
Problems?:           [EMAIL PROTECTED]

Reply via email to