winzip

guys, im new to java.i need a script which takes files from two different directories ,zip them and add that as a url in a html page. ALternative: i can manage with the rest of the code if anybody can tell me how to zip files using java
[250 byte] By [crazypointera] at [2007-9-27 8:38:17]
# 1

I believe you are in the wrong forum. I think you want a form which deals with Javascript (Netscape) or Jscript (Microsoft), HTML scripting.

You could write an appet which does this but then you have all sorts of secrity and sandbox problems since the applet would want to execute a command and write to the hard drive.

BillBlalocka at 2007-7-8 16:55:56 > top of Java-index,Archived Forums,New To Java Technology Archive...
# 2
...,zip them ...Sounds to me you could use classes java.util.zip.ZipInputStream and java.util.zip.ZipOutputStream......and add that as a url in a html page.I'm not sure what you mean by this. Please elaborate...
hdevaana at 2007-7-8 16:55:56 > top of Java-index,Archived Forums,New To Java Technology Archive...
# 3

thanks

we have like a 1000 pairs of files (one with .sdw and another .sid extensions) in one directory and another 1000 set of files in another directory(around 5 of them in each set with extensions .jpg,.bip.....).what we have to do is take one pair from the first directory, one set from the second directory combine them and zip them.

ex:

dir1

a1.sdw, a1.sid

a2.sdw, a2.sid

a3.sdw, a3.sid

a4.sdw, a4.sid

a5.sdw, a5.sid

.

.

.

1000

dir2

a1.jpg, a1.bip........a1.bmp

a2.jpg, a2.bip........a2.bmp

a3.jpg, a3.bip........a3.bmp

.

.

.

1000

now combine a1.sdw, a1.sid from the first dir and a1.jpg, a1.bip........a1.bmp from the sec directory

and zip them and place that as a url in a html page.

i hope i am clear. thanks.

crazypointera at 2007-7-8 16:55:56 > top of Java-index,Archived Forums,New To Java Technology Archive...