title: How can I make categories in a image gallery in Django
body: <p>Hi I'm a graphic designer and very new in programing, I've been learning Python for a while and wanna try something with Django, I'm making my website with Django just for fun and practice and I made this image gallery following some tutorials, but I want to add categorization to the images so in my website I can call some images by categorization and not showing up all the images at once. How can I do that?</p>
  
  <p>MODELS.PY</p>
  
  <pre><code>from __future__ import unicode_literals
  from django.db import models
  
  # Create your models here.
  class Photo(models.Model):
      title = models.CharField(max_length = 200)
      width = models.IntegerField(default = 0)
      height = models.IntegerField(default = 0)
      image = models.ImageField(null= False, blank = False, width_field="width", height_field="height")
      timestamp = models.DateTimeField(auto_now_add = True, auto_now = False)
  
  def __unicode__(self):
      return self.title
  
  class Meta:
      ordering = ["-timestamp"]
  </code></pre>
  
  <p>VIEWS.PY</p>
  
  <pre><code>from django.shortcuts import render, redirect
  from django.http import HttpResponse
  from apps.photos.models import Photo
  
  # Create your views here.
  def photo_list(request):
      queryset = Photo.objects.all()
      context = {
      "photos": queryset,
  }
  return render(request, 'photos/photos.html', context)
  </code></pre>
  
  <p>PHOTOS.HTML</p>
  
  <pre><code>{% extends 'base/base.html' %}
  
  {% block contenido %}
  &lt;br&gt;
  &lt;br&gt;
  {% for photo in photos %}
  &lt;h1&gt;{{ photo.title }}&lt;/h1&gt;
  {% if photo.image %}
  &lt;img src="{{ photo.image.url }}" class="img-responsive"&gt;
  {% endif %}
  {% endfor %}
  {% endblock  %}
  </code></pre>