Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Activity
    Alexander Kozhevin
    @AlexanderKozhevin
    ng-file-upload
    How can I use image preview?
    uyilmaz
    @uyilmaz
    Is there a way to set Content-Type for individual parts of multipart request? Spring cannot pick up a file + a json part in a single request if json part's content type isn't set. Plus, there's a method called Upload.json() but there isn't a .json method in Upload service.
    Mumshad Mannambeth
    @mmumshad
    anybody know how to upload multiple files at once with Node.JS?

    I am trying to upload multiple files in Angular, backend NodeJS

    Upload.upload({
                url: '/api/updateReport',
                fields: metadata,
                file: [imageFile, reportFile, additionalFile]
            })

    On the server end, I try to get them like this:

    var file = req.files.file;
    imageFile = file[0]
    reportFile= file[1]
    additionalFile= file[2]

    The problem is it is not always in the same order. Sometimes they mix up. ie imageFile is not the First file.

    How do I get around this?

    I tried to send data like below. But I can't seem to read the data on the server end. I am using 'connect-multiparty' middleware.

    Upload.upload({
                url: '/api/updateReport',
                fields: metadata,
                data: {imageFile: imageFile, reportFile: reportFile, additionalFile: additionalFile}
            })
    Chad Robinson
    @krptodr
    Hey I stumpled upon an issue with validation. danialfarid/ng-file-upload#1868
    Rick Warren
    @rickwarren
    Anyone else to provide me with an example of replicating the functionality of ng-file-upload within PHP? I have a PHP application that I need to create an upload endpoint in that will communicate properly with an angular application. what I have written isn't returning the correct format of object containing the uploaded file url for it to reference. any help would be greatly appreciated.