v0.1

Custom Fields
#99 - Custom File Inputs
Turn anything into a file input!
Add a file uploader to any site and send the submission to Google Drive, email, or anywhere you want.
Watch the video for step-by-step implementation instructions
<!-- 💙 MEMBERSCRIPT #38 v0.1 💙 FORM FILE UPLOADER -->
<script>
const forms = document.querySelectorAll('form[ms-code-file-upload="form"]');
forms.forEach((form) => {
form.setAttribute('enctype', 'multipart/form-data');
const uploadInputs = form.querySelectorAll('[ms-code-file-upload-input]');
uploadInputs.forEach((uploadInput) => {
const inputName = uploadInput.getAttribute('ms-code-file-upload-input');
const fileInput = document.createElement('input');
fileInput.setAttribute('type', 'file');
fileInput.setAttribute('name', inputName);
fileInput.setAttribute('id', inputName);
fileInput.required = true; // delete keywordthis line to make the input optional
uploadInput.appendChild(fileInput);
});
});
</script>Import this into Make.com to get started
More scripts in Custom Fields