This may be a repettive question. But I have searched the web a lot
before posting this here.
I could not find an easy way of doing this.
Here is my requirement.
I want to upload a gif,jpeg file from my system to the TOMCAT server,
In addition I would like to
1. Specify my desired name for the uploaded files into the server.
2. Specify the directory into which I want these files to be uploaded
Filering for gif,jpeg is also fine, if it is easy, but this is not a
must.
Roedy Green - 24 Oct 2005 09:37 GMT
>Here is my requirement.
>I want to upload a gif,jpeg file from my system to the TOMCAT server,
>In addition I would like to
>
>1. Specify my desired name for the uploaded files into the server.
>2. Specify the directory into which I want these files to be uploaded
You do that with an FTP upload utility. Some of them have scripting.
I have not yet run across any I would find acceptable for fully
unattended use. On my to do list is writing one, probably use the
Apache library or Peter van der Linden's work.
See http://mindprod.com/jgloss/ftp.html
See http://mindprod.com/projects/smartftp.html
for what I consider a suitable tool for the task.
If by any miracle you have a budget for that task, I would love to
write it for a fee.

Signature
Canadian Mind Products, Roedy Green.
http://mindprod.com Again taking new Java programming contracts.
Andrew Thompson - 24 Oct 2005 09:50 GMT
> I could not find an easy way of doing this.
Define 'easy'.
> Here is my requirement.
> I want to upload a gif,jpeg file from my system to the TOMCAT server,
> In addition I would like to
>
> 1. Specify my desired name for the uploaded files into the server.
> 2. Specify the directory into which I want these files to be uploaded
Servlets that can list and link to files (and directories),
create directories and upload files should do the trick.
Allowing user uploads is a security head-ache, though.
You will probably wake up one morning to find that
your site was removed by the server admin. after serving
a gigabyte of child pornography that came from users
you have never heard of. Server admin. may inform you
that the local legal authorities are interested in having
a long chat, as well.
PeanutPete - 24 Oct 2005 10:20 GMT
> > I could not find an easy way of doing this.
>
[quoted text clipped - 18 lines]
> that the local legal authorities are interested in having
> a long chat, as well.
PeanutPete - 24 Oct 2005 10:22 GMT
> > I could not find an easy way of doing this.
>
[quoted text clipped - 18 lines]
> that the local legal authorities are interested in having
> a long chat, as well.
You should have a look at the commons file upload project. It only
takes a few lines of code to let you upload a file.
http://jakarta.apache.org/commons/fileupload/
juhunu@gmail.com - 24 Oct 2005 13:07 GMT
Thanks a lot for your replies...
http://jakarta.apache.org/commons/fileupload/ helped
and I have started using it...
Btw. easy means....using Commons fileUpload