Today I ran into a situation that I’m sure is common:
One of our clients needed a way for their users to be able to upload files to a folder accessible to our client in order to conduct their business. Normally we would just create a form with a file upload field that pointed to a folder on the server and attach an email address to it so the client would be notified when a file was uploaded.
Because our client deals with print, the file sizes they deal with tend to be pretty large. This causes a problem because our servers have a maximum execution time of 30 seconds and a maximum file upload size of 16mb for security and server performance reasons.
We discovered that we were able to upload about 7.5 – 9mb before the server killed the script that was uploading the file. I don’t want to compromise the server performance or security so what do I do?
After some research I found a solution. It’s a two part solution that seems to be just as effective as the way we were going about it before the recent changes to our server.
The first part is to sign up for a Dropbox account. Dropbox is free and accessible from anywhere. Doesn’t get much better or more convenient than that!
The second part is to head over to JotForm for Dropbox. Once you are there you can attach your Dropbox account via a simple login process and then you can create a custom form for your clients, users, etc. to upload files to your Dropbox account. Without signing up for an account with JotForm you’ll get 20 submissions per month, but with a free account you’ll get 100. If you think you’ll be getting more than 100 submissions per month, they have a couple of paid plans that might be of interest to you as well.
After you’ve created your form, you can grab the embed script and put it pretty much anywhere that accepts javascript.
The best part about this setup is that, because JotForm hosts the javascript file, they control the file upload size and the maximum execution time and it has no impact on your server’s performance or storage space!
Do you have any similar solutions for file sharing like this? Post them in the comments!
