title: form object has no attribute 'isValid' in django
body: <p>If i print <code>request.POST.username</code> and <code>request.POST.password</code>, i am getting right data. But i am not able to verify form. And i am not able to get <code>cleaned_data</code>.    </p>
  
  <p><strong>views.py</strong></p>
  
  <pre><code>def login(request):
      if request.method == 'POST':
          form = LoginForm(request.POST)
          if form.isValid():
              print "coming"
          return render_to_response('html/index.html')
      else:
          form = LoginForm()
          c = {'logInForm': form, }
          return render_to_response('html/index.html', c, RequestContext(request))
  </code></pre>
  
  <p><strong>forms.py</strong></p>
  
  <pre><code>from django import forms
  class LoginForm(forms.Form):
      username = forms.EmailField()
      password = forms.CharField(max_length=50)
  </code></pre>
  
  <p><strong>index.html</strong></p>
  
  <pre><code>&lt;!DOCTYPE html&gt;
  &lt;html&gt;
  &lt;head&gt;
      .....
  &lt;/head&gt;
  &lt;body&gt;
  
  &lt;div class="container"&gt;
  
      &lt;form class="form-signin" action="login" method="post"&gt;{% csrf_token %}
          {{ logInForm.as_p }}
          &lt;input type="submit" value="Submit"/&gt;
      &lt;/form&gt;
  &lt;/div&gt; 
  &lt;/body&gt;
  &lt;/html&gt;
  </code></pre>