Table of Contents

Javascript plugins

fileuploader

https://innostudio.de/fileuploader/


Notes
  1. ~~codedoc:xref:preloading~~ Pre-loading files
    • [{
          name: 'file.txt', // file name
          size: 1024, // file size in bytes
          type: 'text/plain', // file MIME type
          file: 'uploads/file.txt', // file path
          local: '../uploads/file.txt', // file path in listInput (optional)
          data: {
              thumbnail: 'uploads/file_thumbnail.jpg', // item custom thumbnail; if false will disable the thumbnail (optional)
              readerCrossOrigin: 'anonymous', // fix image cross-origin issue (optional)
              readerForce: true, // prevent the browser cache of the image (optional)
              readerSkip: true, // skip file from reading by rendering a thumbnail (optional)
              popup: false, // remove the popup for this file (optional)
              listProps: {}, // custom key: value attributes in the fileuploader's list (optional)
              your_own_attribute: 'your own value'
          }
      }]
  2. ~~codedoc:xref:ajaxpreload~~ /ajax/fileuploader.php - action:"preload"
    • response = array[
        name: "IMG_20200301_150420 (1).jpg"
        type: "image/jpeg"
        size: "821914"
        file: "/foto/albums/fotos/004/IMG_20200301_150420 (1).jpg"
        data:
         readerForce: true
         isMain: "0"
         headline: "Mercedes, Meldert, Stephan Vanfleteren,2004"
         description: null
         url: "/foto/albums/fotos/004/IMG_20200301_150420 (1).jpg"
         date: null
         width: "1920"
         height: "1483"
         size: "821914"
         size2: "803 KB"
         thumbnail: "/foto/albums/thumbs/004/IMG_20200301_150420 (1).jpg"
         thumbnail_width: "388"
         thumbnail_height: "300"
         thumbnail_size: "54363"
         thumbnail_size2: "53.1 KB"
         orig: "/foto/albums/origs/004/IMG_20200301_150420 (1).jpg"
         orig_width: "1920"
         orig_height: "1483"
         orig_size: "821856"
         orig_size2: "803 KB"
         listProps: {id: "1"}
         metadata:
           summary: {Headline: "Mercedes, Meldert, Stephan Vanfleteren,2004"}
           exif: {FileName: "IMG_20200301_150420 (1).jpg", FileDateTime: 1586764120, FileSize: 821914, FileType: 2, MimeType: "image/jpeg", …}
           iptc: {Headline: "Mercedes, Meldert, Stephan Vanfleteren,2004", Description: "Mercedes, Meldert, Stephan Vanfleteren,2004", Creator: "Kris Gielen", Location: "FOMU", City: "Antwerpen", …}
           regions: []
         format: "image"
  3. ~~codedoc:xref:filesAddData~~ files.add() –> data
    • data = {
        name: "IMG_20200301_150420 (1).jpg"
        title: "IMG_20200301_150420 (1)"
        size: 821856
        size2: "803 KB"
        type: "image/jpeg"
        format: "image"
        extension: "jpg"
        data: {}
        file: File {name: "IMG_20200301_150420 (1).jpg", lastModified: 1586083807175, lastModifiedDate: Sun Apr 05 2020 12:50:07 GMT+0200 (Central European Summer Time), webkitRelativePath: "", size: 821856, …}
        reader: {read: ƒ}
        id: 1586790020907
        input: w.fn.init [input.gallery_media]
        html: null
        choosed: true
        appended: false
        uploaded: false
      };