title: How to create a custom django filter tag
body: <p>I am having trouble in getting my site to recognise custom template tags.  I have the following dir structure:</p>
  
  <ul>
  <li>project_name
  
  <ul>
  <li>project_name
  
  <ul>
  <li>templatetags
  
  <ul>
  <li>_ __init __ _.py</li>
  <li>getattribute.py</li>
  </ul></li>
  <li>views
  
  <ul>
  <li>_ __init __ _.py</li>
  <li>index.html</li>
  </ul></li>
  <li>views</li>
  <li>settings.py</li>
  <li>main.py</li>
  <li>manage.py</li>
  <li>urls.py</li>
  </ul></li>
  <li>nbproject</li>
  </ul></li>
  </ul>
  
  <p>Then I have added this to the INSTALLED_APPS:</p>
  
  <pre><code>INSTALLED_APPS = (
  #    'django.contrib.auth',
      'django.contrib.contenttypes',
  #    'django.contrib.sessions',
      'django.contrib.sites',
      'project_name'
  )
  </code></pre>
  
  <p>I then reference this inside the template like this:</p>
  
  <pre><code>{% load getattribute %}
  {%  for header in headers %}
      &lt;td&gt;{{ obj|getattribute:header }}&lt;/td&gt;
  {% endfor %}
  </code></pre>
  
  <p>The error which I get is as follows:</p>
  
  <blockquote>
    <p>Could not import
    controllers.EventController. Error
    was: No module named project_name</p>
  </blockquote>
  
  <p>Any help would be appreciated for this:</p>
  
  <p>TIA</p>
  
  <p>Andrew</p>
  
  <p><strong>UPDATE:</strong></p>
  
  <p>The site works but I cannot get the template tags to work.  If I remove the project_name from the installed_apps I get the following error:</p>
  
  <blockquote>
    <p>Exception Value:      'getattribute' is
    not a valid tag library: Could not
    load template library from
    django.templatetags.getattribute, No
    module named getattribute</p>
  </blockquote>