Author | Message |
---|---|
victormejia
Posts: 40
|
Posted 14:09 Nov 18, 2010 |
In what directory are the files uploaded? I tried searching deep within the .metadata folder but can't seem to find it.
|
HuanXue
Posts: 34
|
Posted 14:43 Nov 18, 2010 |
It's the path which you decided in build.properties |
victormejia
Posts: 40
|
Posted 16:41 Nov 18, 2010 |
great thanks.
|
HuanXue
Posts: 34
|
Posted 17:04 Nov 18, 2010 |
I use the same way to delete but I don't know your own way to get that "file". But if you are not deleting a folder on csns, I think you only need to make sure that you get the correct path, i.e. correct "basedir" & " id" & "version". |
Phobe
Posts: 40
|
Posted 17:20 Nov 18, 2010 |
You can call getDiskFile() and check if the file exists and get the full path. Most likely the file won't exist. I ran into a similar problem and found that fileDao.getFileById() returns the correct file object, but the baseDir isn't set. Once the baseDir is set correctly, it should point to the right file. |
victormejia
Posts: 40
|
Posted 17:43 Nov 18, 2010 |
Yea I am getting the same thing. All values are set correctly but when I try to retrieve the baseDir, it's null. How did you make sure it is set correctly? |
victormejia
Posts: 40
|
Posted 17:48 Nov 18, 2010 |
I got it; once I get the it from the database I set the baseDir again. Not sure if it's correct but it works |
kknaur
Posts: 540
|
Posted 18:34 Nov 18, 2010 |
If you look at your database Files table you will notice there is no basedir column unless you created it back when you altered the Files table. Since this is the case, of course the basedir property would be null as there is no corresponding column to set that property. As someone previously mentioned, it is necessary to set the basedir of the file object you want to save at upload time. |