2👍
You may want to look at a custom ImageField, which would handle your custom processing in its clean method. Take a look at this for instance: https://djangosnippets.org/snippets/2206/
0👍
I would do it in the form class itself by overriding the clean method and checking it.
when you call is_valid() from your view then it will inturn call the clean method where you can do this checking.
- [Answered ]-Django-admin brite force protection and more
- [Answered ]-How do I reset template loader cache in Django 1.9?
- [Answered ]-Django rest framework custom serializer using foreign key
Source:stackexchange.com