GuidePedia

0
How to Receive Files in your Google Drive from Anyone
A school teacher wants to have a public drop box (not Dropbox) where students can upload homework assignments. A recruiter wants to have an online form where job applicants can upload their resumes. A news organization may need a public drop box where people can upload files anonymously.



Google Forms would have been a perfect solution here but unfortunately you cannot upload files to Google Drive through Forms.
The other option is to have a shared folder inside Google Drive but there are limitations. One, you need a Gmail Account and should be invited by the folder owner to upload files in a shared folder. Second, all collaborators can view and even remove files that have been uploaded in a shared folder on Google Drive.





Drive Form with File Uploads 

Receive Files in Google Drive with Forms

What you can do is create a regular web form (written in HTML and CSS) and then use Google Apps Script to post the content of this form into Google Drive.
Before diving into the implementation, take a look at this sample form. When you upload a file, it will show up in a specific folder on my Google Drive. You don’t even need to have a Google Account to upload files and the Google Script based form even works on mobile devices.
  • Click here to make a copy of the Google Script into your Google Drive.
  • This is vanilla form with a text field, a file input field and a form submit button. You can open the form.html file to apply your own CSS styles or add more input and textarea fields.
  • From the Run menu, choose doGet and authorize the script. The script needs these permissions since the form will be uploading files to your Google Drive.
  • Next choose Deploy as Web App from the Publish menu. Click Save New Version, choose Anyone, even Anonymous from the drop-down and click the Deploy button.
The Google Script will now offer you a form URL. Anyone can now use this form to upload files to your Google Drive.


 

Post a Comment

 
Top