Django ImageField widget that accepts upload or external link as source

1k views Asked by At

Is there a Django widget for ImageFields that provides the option to either upload an image or provide a url?

I'm thinking like Summernote does (if you click the image icon) in its examples

I've browsed through many apps and they are all focused on just uploading and thumbnailing.

EDIT

Still working on trying to do be able to do this. I'm looking for something like the way django-summernote allows you to add images.

Also taking a look at this question about saving an image link into an ImageField. How can I get both to work together ina widget like Summernote?

Django save image from url and connect with ImageField

2

There are 2 answers

4
Oleksandr On

ImageFields based on FileField and can save only path to file with current media backend.

For save image from external url you should get link in separately form field and download this picture in tmp file and save to ImageFields.

0
43Tesseracts On

No. This widget does not yet exist. You should make it.