title: Django 1.3 static files and displaying content using custom views
body: <p>A slight problem displaying an image using custom views.
  I have used the request context as required, however the image doesn't show.</p>
  
  <p>My model uses thumbnails creating the image into a folder named "timgs" which lives under static/myapp/timgs</p>
  
  <p>The static files directory displays css/images fine however when it comes to a custom view images do not display.</p>
  
  <p>Ive tried listing the specific folder in settings like this. with no luck.</p>
  
  <pre><code>STATICFILES_DIRS = (
      os.path.join(PROJECT_DIR, 'static/myapp/'),
      ("timgs", "/timgs"),
  )
  </code></pre>
  
  <p>I would be very grateful if someone would be kind enough to explain what's wrong, maybe provide a simple example.
  Thank you.</p>
  
  <p><strong>view/template</strong></p>
  
  <pre><code>def function(request):
      whatever = ____.objects.all()
      return render_to_response('template', {
          'whatever': whatever,
      }, context_instance=RequestContext(request))
  
  
      {% for whatever in whatever %}
          &lt;li&gt;{{ whatever.text }}&lt;/li&gt;
          &lt;li&gt;&lt;img src="{{ whatever.image.thumbnail }}" /&gt;&lt;/li&gt;
      {% endfor %}
  </code></pre>
  
  <p><strong>settings</strong></p>
  
  <pre><code>MEDIA_ROOT = ''  
  MEDIA_URL = ''
  STATIC_ROOT =  os.path.join(PROJECT_DIR, 'static/')  
  STATIC_URL = '/static/'
  ADMIN_MEDIA_PREFIX = '/static/admin/'
  </code></pre>