title: Django AttributeError: calling form.is_valid() always results in Object has no attribute 'is_vaild'
body: <p>I've been searching for solutions for a whole day and I have almost gone through all the answers on Stackoverflow and still cannot solve my problem. So, I have to raise this question. </p>
  
  <p>In models.py, I have:</p>
  
  <pre><code>from django.db import models
  import datetime
  from django.utils import timezone
  
  class Cap(models.Model):
  
      title = models.CharField(max_length=50)
      user_id = models.CharField(max_length=100)
      dest_id = models.CharField(max_length=100)
      cap_id = models.CharField(max_length=500)
  
      text_part = models.FileField(upload_to='texts/%Y/%m/%d')
  
      time_to_live = models.IntegerField()
      pub_date = models.DateField()
  
      def __unicode__(self):
          return self.title
  </code></pre>
  
  <p>Then in forms.py, I have:</p>
  
  <pre><code>from django.forms import ModelForm
  
  from latercap.models import Capsule
  
  class CapForm(ModelForm):
      class Meta:
          model = Cap
          fields = '__all__'
  </code></pre>
  
  <p>Then in views.py, I have:</p>
  
  <pre><code>from django.shortcuts import render
  from django.http import HttpResponseRedirect
  from myapp.forms import CapForm
  
  def upload(request):
      # Handle file upload
      if request.method == 'POST':
          form = CapForm(request.POST, request.FILES)
          if form.is_vaild():
              form.save()
              # Redirect to the upload page after POST
              return HttpResponseRedirect('/myapp/upload/')
      else:
          form = CapForm() # An empty, unbound form
  
      message = "You can upload your message here!"
      context = {'message': message, 'form': form}
  
      # Render upload page with the documents and the form
      return render(request, 'myapp/upload.html', context)
  </code></pre>
  
  <p>Then in upload.html, I have:</p>
  
  <pre><code>&lt;b&gt;{{message}}&lt;/b&gt;
  
  &lt;form action="{% url 'myapp:upload' %}" method="post" enctype="multipart/form-data"&gt;
      {% csrf_token %}
      &lt;p&gt;{{ form.non_field_errors }}&lt;/p&gt;
      &lt;p&gt;Title: {{ form.title }}&lt;/p&gt;
      &lt;p&gt;From: {{ form.user_id }}&lt;/p&gt;
      &lt;p&gt;To: {{ form.dest_id }}&lt;/p&gt;
      &lt;p&gt;No. {{ form.cap_id }}&lt;/p&gt;
      &lt;p&gt;Open after: {{ form.time_to_live }}&lt;/p&gt;
      &lt;p&gt;Publish date: {{ form.pub_date }}&lt;/p&gt;
      &lt;p&gt;My message:&lt;/p&gt;
      &lt;p&gt;
         {{ form.text_part }}
      &lt;/p&gt;
      &lt;p&gt;&lt;input type="submit" value="Upload" /&gt;&lt;/p&gt;
  &lt;/form&gt;
  </code></pre>
  
  <p>When I set correct values into the form and click "Upload" button, I ALWAYS get:</p>
  
  <pre><code>&gt; AttributeError at /myapp/upload/ 'CapForm' object has no attribute
  &gt; 'is_vaild'
  &gt; Request Method:   POST Request
  &gt; URL:  http://127.0.0.1:8000/myapp/upload/
  &gt; Django Version:   1.6.5
  &gt; Exception Type:   AttributeError Exception Value:  'CapForm' object
  &gt; has no attribute 'is_vaild'
  </code></pre>
  
  <p>I have tried:</p>
  
  <ul>
  <li><code>print form.errors</code>, but nothing was shown</li>
  <li><code>print form.is_valid()</code> before the <code>if</code>, still gives the error</li>
  <li>delete the <code>text_part</code> and only pass <code>request.POST</code> to the <code>form</code>, still gives errors</li>
  <li>use <code>form(data=request.POST, files=request.FILES)</code>, still errors</li>
  <li><code>print form.is_multipart()</code> give me a <code>True</code> result</li>
  <li>submit an empty or correctly filled form all give the same error</li>
  </ul>
  
  <p>What should I do to get this work? Many many thanks!</p>