title: Django: How Add Static Files
body: <p>Readed all these topic <a href="https://stackoverflow.com/search?q=django.views.static.serve">https://stackoverflow.com/search?q=django.views.static.serve</a>
  And it not helped :(</p>
  
  <p>OS: Windows XP
  Python: 2.7
  Django: 1.2.3</p>
  
  <p><b>Media in</b><br/>
  D:\bugtracker\static</p>
  
  <p><b>With files:</b><br/>
   docicons-note.gif<br/>
   style.css</p>
  
  <p>In <b>settings.py</b> i set:<br/>
  MEDIA_ROOT = 'D:/bugtracker/static/'<br/>
  MEDIA_URL = '/static/'<br/></p>
  
  <p>In <b>urls.py</b> i set:<br/></p>
  
  <pre><code>urlpatterns = patterns('',
      (r'^media/(?P.*)$', 'django.views.static.serve',{'document_root':'settings.MEDIA_ROOT'}),
  )</code></pre>
  
  <p><b>template:</b> (read it without space in &lt; tag>)<br/>
  <code>&lt; !DOCTYPE html>
  &lt; html lang='ru'><br/>
  &lt; head><br/>
   &lt; link rel="stylesheet" type="text/css" href="media/style.css" /><br/>
  &lt; /head><br/>
  &lt; body><br/>
   &lt; img src="{{MEDIA_URL}}/docicons-note.gif"/><br/>
  &lt; /body><br/>
  &lt; /html>
  </code></p>