vendredi 4 janvier 2019

When I submit larger file with AJAX jQuery to Laravel 5 controller, it getting empty data

When I try uploading an image file using jQuery ajax request to Laravel controller, the output in the controller is empty. But when I upload a small size file it's able to access but not the larger one. (I am using laravel version 5.7.*)

Note: I had updated my php.ini file for file uploading limits and post upload limits to 50M. Even though it's giving the same problem.

I had updated my php.ini file for file uploading limits and post upload limits to 50M. Even though it's giving the same problem.

$.ajax({
    method: "POST",
    url: 'photo-upload',
    data: formData, // I had appended all the data to this FormData();
    success: function(result){
           swal("Success","Uploaded Successfully","success");
    },
    cache: false,
    contentType: false,
    processData: false
});

// Inside Controller

$photo = Input::file('photo'); // It's giving empty result with larger file



from Newest questions tagged laravel-5 - Stack Overflow http://bit.ly/2Vs1XqW
via IFTTT

Aucun commentaire:

Enregistrer un commentaire