Hi,
Making URLConnection to a directory under WEB-INF, is the same like writing
this url in the explorer.
However, You can't go directly to any directory under WEB-INF in that way,
which justifies your failure of
writing to this directory.
You can write to files in this directory, if you don't
Instead there is a method in the servlet context : getRealPath(String
relativefilename) - then you can open a normal fileoutputstream.
-Original Message-
From: tamir [mailto:[EMAIL PROTECTED]]
Sent: 24 June 2002 11:31
To: 'Tomcat Users List'
Subject: RE: Can servlet write to file
this helps.
Les
-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
Sent: 24 June 2002 09:13
To: [EMAIL PROTECTED]
Subject: RE: Can servlet write to file in /WEB-INF?
Instead there is a method in the servlet context :
getRealPath(String relativefilename
directory you set up (you could store the location of this other
directory as a property in your web.xml file, etc.).
-Original Message-
From: Les Hughes [mailto:[EMAIL PROTECTED]]
Sent: Monday, June 24, 2002 3:08 AM
To: 'Tomcat Users List'
Subject: RE: Can servlet write to file in /WEB-INF
On Sat, 22 Jun 2002, john-paul delaney wrote:
I was trying to see if I could write to a file in the /WEB-INF
directory but I couldn't get it to work - is there a problem with a
servlet writing to this directory or is it just me (again ;( ) ?
thanks
/j-p.
URL url =
Thanks Milt... yes I'm reading servlet programming by the same author, he'd written a
servlet example that reads and writes a counter to an external file resource but it
seems the file location varies depending on the container implementation - I was
trying to understand how to determine an
On Sat, 22 Jun 2002, john-paul delaney wrote:
Thanks Milt... yes I'm reading servlet programming by the same
author, he'd written a servlet example that reads and writes a
counter to an external file resource but it seems the file location
varies depending on the container implementation - I