I’m working on a web application which needs to download/upload a file from/to the server. The user base for this application, however, is not tech savvy so we we want them to click a button that indicates “Download file” (for this record) or “Upload file” (for this record) without having to rely on the user to “Save As” or indicate the destination folder. In a previous version we’ve used Software Artisan’s SAXFile (an ActiveX control) however we’re trying to avoid ActiveX this time around. We’re hoping to make the application browser agnostic.
Any suggestions about how to do this? I’m assuming we’ll have to do a java applet, but if there’s an existing open source project or control I’d rather not roll my own.
This is a security issue, that’s why there’s not many good options out there. The ability to write to an arbitrary directory is definitely not something that should be granted to any web page.
Your options are a Java Applet, Flash, HTML5, or ActiveX, but all of those require the user to grant permissions, or select a location. You could also accomplish this with HTML5 Web storage, which doesn’t require user permissions, but is more limited, both in storage format, browser support, and size limits (5 or 10 MB for most browsers)