cocoon-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Steve Schwarz" <>
Subject Re: Fw: Uploading files with Cocoon 2.1 (one more)
Date Fri, 28 Nov 2003 14:03:59 GMT
Hmmm. I haven't checked the archives to see what I posted. But it is 
possible I cut and pasted with some error....I'm very sorry if that is the 
case! I didn't just attach the action since it wouldn't persist in the mail 
archives that way.

In my code I have:
		// Create the upload folder(s) if need be
		File folder = new File(uploadFolder);
		if (!folder.exists()) {

	File destFile =
		new File(folder + File.separator + filename);
// code that does the copy

So the creation of the directories is independent from the file copying..

>File folder = new File (uploadfolder);
>if (!folder.exists()){
>//code for uploading and saving a file
>That generates the next problem: if you upload a file, a folder is created,
>and the file is saved into this folder.

So if you make the change as you indicate I'm sure all is well. (?)

Set yourself up for fun at home!  Get tips on home entertainment equipment, 
video game reviews, and more here.

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message