Page 1 of 1
How to view file when clicked?
Posted: Wed Apr 01, 2009 1:59 pm
by rickburgen
I built a website that allows users to upload files to a personal folder. I developed the so far, so that the user can see which fille they uploaded. Now, I want to add the functionality so that when they click the link(their file) it shows them what it is. Like quick look for OS X. I hope I got my point across. How would I go about this? Thanks.
Re: How to view file when clicked?
Posted: Thu Apr 02, 2009 11:58 pm
by jaoudestudios
Re: How to view file when clicked?
Posted: Fri Apr 03, 2009 12:06 am
by miyur
now that would depend the kind of file uploaded. if it's a simple text file or a doc file you could open it up for the user but in case of multimedia files, it might get difficult. what you could do is show user the file details first like the upload time, type of file, file description etc., and you can provide a download option along with it for the user there.
Re: How to view file when clicked?
Posted: Fri Apr 03, 2009 6:01 am
by rickburgen
I don't want the user to have to download the file after they just uploaded it., that would be a major inconvenience and would probably drive them away from the site. How would I get the date of when the file was uploaded, and size, and type? Are there built in methods? At the current state of the links, when they are clicked it asks if I want to download it, but the type is Untyped Binary Data. I never heard of that.