Last active
December 17, 2015 20:09
-
-
Save Kaapiii/5665576 to your computer and use it in GitHub Desktop.
Dropzone.js quick configuration
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Dropzone.options.mydropzone = { | |
//url: null, | |
//method: "post" | |
parallelUploads: 2, | |
maxFilesize: 0.31, // MB | |
//paramName: "file", // The name that will be used to transfer the file | |
//createImageThumbnails: true, | |
//maxThumbnailFilesize: 10, | |
thumbnailWidth: 100, | |
thumbnailHeight: 100, | |
//params: {}, | |
//clickable: true, | |
acceptedMimeTypes: "image/*", //"audio/*,video/*,image/*,application/pdf" | |
//enqueueForUpload: true, | |
previewsContainer: null, // if preview of uploads should be displayed in ohter element than uploadfield | |
dictDefaultMessage: "Ziehen Sie die Bilder in diesen Bereich. Drop files here to upload", | |
dictFallbackMessage: "Ihr Browser unterstütz den drag'n'drop Bilderupload nicht. Your browser does not support drag'n'drop file uploads.", | |
dictFallbackText: "Bitte benutzen Sie das alternativ Formular zum Bilder hoch zu laden. Please use the fallback form below to upload your files like in the olden days.", | |
dictFileTooBig: "Die Datei is zu gross ({{filesize}}MB). Maximal erlaubte gösse: {{maxFilesize}}MB. File is too big ({{filesize}}MB). Max filesize: {{maxFilesize}}MB.", | |
dictInvalidFileType: "Dieser Dateitype ist nicht erlaubt. You can't upload files of this type.", | |
dictResponseError: "Die Dateien konnten nicht hochgeladen werden. {{statusCode}} Server responded with {{statusCode}} code.", | |
/*accept: function(file, done){ | |
console.log(file); | |
//if() | |
done(); | |
},*/ | |
// Testing | |
//forceFallback: false | |
}; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
More on: http://reference.sitepoint.com/html/mime-types-full | |
// "audio/*,video/*,image/*,application/pdf" | |
// Compressed | |
// *.gzip "multipart/x-gzip,application/x-gzip" | |
// *.zip "application/x-compressed,application/x-zip-compressed,application/zip,multipart/x-zip" | |
// Adobe | |
// *.eps "application/postscript" | |
// *.psd "application/octet-stream" | |
// *.tif and *.tiff "image/x-tiff,image/tiff" | |
// Office MS | |
// *.dot and *.doc "application/msword" | |
// *.xls "application/excel,application/x-msexcel,application/x-excel,application/vnd.ms-excel" | |
// Datatype | |
// *.xml "application/xml,text/xml" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment