February 13th, 2012, 09:25 AM
How to browse a directory
I need to browse a directory rather than a file. I should allow the users to choose the directories rather than a file. I am not sure if it is feasible in cold fusion
Can someone help
February 13th, 2012, 09:44 AM
If you mean you want to have the user choose and upload an entire directory of files, no you can't. And it has nothing to do with ColdFusion (which is a server-side platform), but with the security that the web browser makers have in place.
February 16th, 2012, 10:59 AM
Thanks. Please guide me to an alternate solution
February 16th, 2012, 11:41 AM
The browsers will not allow this, since it is not only a massive security hole but also can be easily abused (what if they pick their entire C:\ drive?).
So you'd have to try using a Java applet, ActiveX control, or possibly a Flash/Flex widget, though I am not sure those will work either since I believe the limitation is built into the web browsers themselves. CF 9 has a tag called cffileupload that will make it easier for the user to pick multiple files to upload, but it can't let the user pick a whole directory to upload.