title: Django match current URL and load template
body: <p>So, I am trying to load a template based on the current URL, and </p>
  
  <p>For example:</p>
  
  <pre><code>{% if 'foo/bar/gallery' in request.path %}
      {% include 'web/custom/foo/bar/gallery.html' %}
  {% endif %}
  </code></pre>
  
  <p>The foo/bar/ is dynamic, as are the directory template locations. The string 'gallery' will always be the same, and can be hardcoded if that matters.
  How can this be achieved?</p>
  
  <p>FYI: still on django 1.3.7</p>