Django Photo Gallery

Django Photo Gallery

Miracle! A free day this weekend. I decided to do clean code so a Python day :). Demo on this link. The sample contains a Django 1.10.x Image Gallery Site. The album images are optimized for performance. The Django Photo Gallery Sample is responsive and mobile / device friendly. No validation on the admin zip file form, but good result for a day and a bit, looks great on my phone! Velin Georgiev blog image

What problem solves Django Photo Gallery?

Should be RESPONSIVE! Should have swipe/slide experience when image gallery is open in image full mode. Should have image zoom experience on phone when image is open in full mode. Its 2017, sadly smartphones overtook the PCs and few use big screens. I could not find good Django Photo Gallery / Album solution in Github that has the above requirements. Maybe I did not search enough, but just decided to do one instead of looking at many not that practical solutions. One very good is django-photologue, however I need to do UI stuff to make it mobile friendly. I just decided to go with mine since I had all day free and wanted to do Django, Python stuff, rather than only UI and configs.

Upload one zip from the Django admin panel and magic happens

I am lazy and definitely not a photographer! I do not want to spend time on the images, I just want to upload zip and have my images ready in album. Velin Georgiev blog image

Resized images with thumbnails

Well noting exiting, every site out there has it, but with fine cache tuning on your Apache server this probably will fly. Thanks to the django-imagekit, the picture size and quality can be controlled programatically from the Just change the processors. For more information see the django-imagekit .
class AlbumImage(models.Model):
    image = ProcessedImageField(upload_to='albums', processors=[ResizeToFit(1280)], format='JPEG', options={'quality': 70})
    thumb = ProcessedImageField(upload_to='albums', processors=[ResizeToFit(300)], format='JPEG', options={'quality': 80})
Available on Github Please note: This is sample and it is not production ready, use django-photologue instead for production or contribute to that project and make it production ready. Do not forget to Github star it if you like it because Sharing is Caring! Cheers, Velin
Siva | 19 Jun 2017


imacoder0 | 26 Apr 2018

hi i am this guy.