title: CSRF verification failed. Request aborted
body: <p>I try to build a very simple website where one can add data into sqlite3 database. I have a POST form with two text input.</p>
  
  <p>index.html:</p>
  
  <pre><code>{% if top_list %}
      &lt;ul&gt;
      &lt;b&gt;&lt;pre&gt;Name    Total steps&lt;/pre&gt;&lt;/b&gt;
      {% for t in top_list %}
          &lt;pre&gt;{{t.name}} {{t.total_steps}}&lt;/pre&gt;
      {% endfor %}
      &lt;/ul&gt;
      {% else %}
      &lt;p&gt;No data available.&lt;/p&gt;
  {% endif %}
  &lt;br&gt;
  &lt;form action="/steps_count/" method="post"&gt;
      {% csrf_token %}
      Name: &lt;input type="text" name="Name" /&gt;&lt;br /&gt;
      Steps: &lt;input type="text" name="Steps" /&gt;&lt;br /&gt;
     &lt;input type="submit" value="Add" /&gt;
   &lt;/form&gt;
  </code></pre>
  
  <p>forms.py:</p>
  
  <pre><code>from django import forms
  from steps_count.models import Top_List
  
  class Top_List_Form(forms.ModelForm):
      class Meta:
          model=Top_List
  </code></pre>
  
  <p>views.py:</p>
  
  <pre><code># Create your views here.
  from django.template import Context, loader
  from django.http import HttpResponse
  from steps_count.models import Top_List
  from steps_count.forms import Top_List_Form
  from django.template import RequestContext
  from django.shortcuts import get_object_or_404, render_to_response
  
  def index(request):
  
  if request.method == 'POST':
      #form = Top_List_Form(request.POST)
      print "Do something"
  else:
      top_list = Top_List.objects.all().order_by('total_steps').reverse()
      t = loader.get_template('steps_count/index.html')
      c = Context({'top_list': top_list,})
      #output = ''.join([(t.name+'\t'+str(t.total_steps)+'\n') for t in top_list])
      return HttpResponse(t.render(c))
  </code></pre>
  
  <p>However, when I click the "submit" button, I get the 403 error:</p>
  
  <pre><code>CSRF verification failed. Request aborted.
  </code></pre>
  
  <p>I have included <code>{% csrf_token %}</code> in index.html. However, if it is a RequestContext problem, I really have NO idea on where and how to use it. I want everything to happen on the same page (index.html).</p>