Multiple image upload using Django, Vuejs and Axiox

Skip to first unread message

Alam Khazi

Nov 20, 2021, 12:07:03 AM11/20/21
By using Vuejs, Axiox and Django, Uploading multiple images. After uploading images are getting in list and then those list of images names we are storing into backend in ImageField image is saving into database but not saving into media folder.

['nature6.jpg', 'nature5.jpg', 'nature4.jpg', 'nature3.jpg', 'nature2.jpg', 'nature1.jpg', 'nature.jpg']
    if request.method == "POST":
        # From template we are fetching values
        data = json.loads(request.body)
images = data['images']
        saveform = vk_service(image=images[0],
Images are saving into database but not saving in media folder.
Please help me out to solve this issue.


Omkar Parab

Nov 20, 2021, 1:19:05 AM11/20/21
Check, whether you've added "upload_to" in your Image Field and add MEDIA_ROOT & MEDIA_URL in file or not. 

You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to
To view this discussion on the web visit

Gabo LaTo

Nov 20, 2021, 6:22:29 AM11/20/21
how are you sending the files from the client?
It seems to me you're reading the files metadata but you are not accessing the image binaries to store them.

Look at this example. It's made in angular but it can give you an idea:

In this case the backend is done with Django Rest Framework so just sending the data as the framework expected make it work:

Reply all
Reply to author
0 new messages