Change filename. Get list of uploaded filesChange filename. Get list of uploaded filesHi, i am considering using Amazon S3 for a website where users can create image galleries. I will most likely have several thousand of galleries if everythings works out. I have found you JS3Upload control and it looks very impressive and just what i need.
But i can see that i am running in a design limitation with the Amazon S3 serverice. You are only allowed to have 100 buckets I order to workaround this limitation i would like to append a guid to the original file name. This will allow me to only use one bucket. Is it possible to specify a prefix as a paramater to your applet and have the prefix appended to the filename? Also is it possible to get access the names of the files being uploaded? I need to store the names (url) of the files in a local database in order to provide the desired functionality on my site. Kind regards Tony Re: Change filename. Get list of uploaded filesWhat about having a new parameter allow defining a virtual folder in a bucket. For instance:
<PARAM NAME="param4" NAME="account"> <PARAM NAME="value4" NAME="user1"> That's way you would upload data into /bucketname/user1/image1.jpg /bucketname/user1/image2.jpg ... I think we could add it in JS3Upload 2.2. Do you plan POST or PUT upload ? Re: Change filename. Get list of uploaded filesHi,
I am very new to the S3 service and wasn't aware that you could create virual folders. That would solve the issue since it allows upload a two files with identical file names into two different virtual folders. Thank you for that information I guess i can use the S3 API to iterate the content of the virtual folder in order to syncronize changes to my local database. Is there an event fired i can subscribe to when J3Upload are done uploading files? e.g redirect the page to an URL with some querystrings paramters or similar that will make it possible to dermine which virtual folder has changed. Re: Change filename. Get list of uploaded filesRegarding POST / PUT ... i will have to be invistigate this a bit futher before i can answer that question.
Re: Change filename. Get list of uploaded filesYes, with "forward" parameter. The applet will redirect to an URL after upload is done.
If you need filenames uploaded to be passed then user "forwardparameters". See the online tutorial at: http://www.jfileupload.com/products/jfi ... irect.html About virtual folders: In fact, S3 works with Object. Each object has a key. The key is the filename but you're free to use a key such as "user1/filename". That's the way you can simulate folders with S3. About POST, PUT choice: In my opinion, the best is POST for upload because it allows "policy" parameter. It means that you do not need to pass your KeyID/SecretKey. Only a signed policy (with upload rules, restrictions ...). We provide a HTML tool to generate such policy: http://www.jfileupload.com/products/js3 ... rator.html Re: Change filename. Get list of uploaded filesThank you for your help. It is very helpfull when trying to figure out the new S3 world!
If you could add support for virtual folders in the next relase i would be very happy. FYI my virtual folders name will be a valid GUID and i am definitely going to use POST due to the policy parameter. Can i subscribe to a newsletter or similar in order to get notifed when the next version has been released? Re: Change filename. Get list of uploaded filesDrop an an email to support(at)jfileupload(dot)com and they will notify you about the update.
Re: Change filename. Get list of uploaded filesThe virtual folder feature is now available. If you need to prepend all filenames uploaded with "virtual/" then use:
<PARAM NAME="param5" VALUE="account"> <PARAM NAME="value5" VALUE="virtual"> I've sent you the link for 2.2 beta by email. Re: Change filename. Get list of uploaded filesHi,
Thank you for the beta code I have not yet been able to test. I am gettings a TemporayRedirect Error. I have create the bucket several hours ago so i think the the amazon DNS must be updated. I can upload using the firefox extension. I have attached an image showing the error message. The only modification i have made to the js file is: PARAM NAME="url" VALUE="http://dodisco.s3.amazonaws.com" Can you spot the error?
Re: Change filename. Get list of uploaded filesYou must keep url with s3.amazonaws.com. Just add the s3bucket parameter such as:
<PARAM NAME="url" VALUE="http://s3.amazonaws.com"> <PARAM NAME="param2" VALUE="s3bucket"> <PARAM NAME="value2" VALUE="dodisco"> Does it help ? Also, did you create an US or an EU bucket ? |