title: Passing extra context to Django Haystack template
body: <p>Setting up a search page with Django Haystack involves putting in their URLconf snippet <code>url(r'^search/', include('haystack.urls'))</code>. However, this means (at least from my extremely basic understanding of Django/MVC), that there is no simple way to pass extra context (i.e. an extra dictionary key/value) to be rendered onto the page.</p>
  
  <p>In particular, I want to customize a search field to mirror the variable passed onto the page from a GET request:</p>
  
  <pre><code>&lt;form method="get" action="."&gt;
  &lt;input type="text" name="q" value=""&gt;
  &lt;!-- result html here --&gt;
  &lt;/form&gt;
  </code></pre>
  
  <p>Say the parameter <code>?q=twitter</code> is attached to the URL as part of a GET request; I'd like to make the <code>value</code> selector equal to <code>twitter</code>. If I had control of the view, I would likely do it something like this:</p>
  
  <pre><code>if request.method == 'GET':
      q = request.GET['q']
      return render(request, 'template.html', {'q': q})
  </code></pre>
  
  <p>And then use <code>q</code> as the value for the <code>value</code> selector in the HTML <code>&lt;input&gt;</code>.</p>
  
  <p>Is there any way to accomplish this in a simple manner, besides editing the Haystack source?</p>