title: Submitting Django Form In Custom HTML
body: <p>I am a newb to django forms and I am trying to create a very specific user interface, so I can't use model forms (or can I?)</p>
  
  <p>I created a custom form that looks like this:</p>
  
  <p>but it won't commit to the db?</p>
  
  <p>This is my html form:</p>
  
  <pre><code>    &lt;form method="POST" action='/create/' id="big_idea_form" class="tabscontent"&gt;{% csrf_token %}
          &lt;label class="tabpage" id="tabpage_1" &gt;&lt;span&gt;next&lt;/span&gt;&lt;p&gt;Give it a name!&lt;/p&gt;&lt;input type="text" id="name"  placeholder="Type your title here" onblur='changeIt("name", "name_span")'/&gt;&lt;/label&gt;
          &lt;label class="tabpage" id="tabpage_2" &gt;&lt;p&gt;What is it about?&lt;/p&gt;&lt;input type="text" id="subtitle" name="subtitle" placeholder="Type your subtitle here" onblur='changeIt("subtitle", "subtitle_span")'/&gt;&lt;/label&gt;
          &lt;label class="tabpage" id="tabpage_3" &gt;&lt;p&gt;Why is it important?&lt;/p&gt;&lt;textarea id="description" name= "description" cols="42" rows="5" placeholder="this can be any description but it becomes more interesting if you can explain why it is important as part of your description" onblur='changeIt("description", "description_span")'&gt;&lt;/textarea&gt;&lt;/label&gt;
          &lt;label class="tabpage" id="tabpage_4" &gt;&lt;p id="success_title"&gt;What is  considered success?&lt;/p&gt;&lt;textarea id="success" name="success" cols="42" rows="5" placeholder="describe what sucess means to your students... what does mastery look like?" onblur='changeIt("success", "success_span")'&gt;&lt;/textarea&gt;&lt;/label&gt;
          &lt;input type="submit" value="Submit"/&gt;        
      &lt;/form&gt;  
  </code></pre>
  
  <p>This is my form:</p>
  
  <pre><code>from django import forms
  import urlparse
  from models import Lesson
  
  class CreateLesson(forms.Form):
      name=forms.CharField()
      subtitle=forms.CharField(required=False)
      creator=forms.CharField() #automate
      description=forms.CharField()
      success=forms.CharField()
      unit=forms.CharField(required=False)
      public=forms.BooleanField()
  
      def save(self, request):
      data=self.cleaned_data
      Lesson.creator = request.user
      Lesson.name=data.get('name', '')
      Lesson.subtitle=data.get('subtitle', '')
      Lesson.topic=data.get('topic', '')
      Lesson.description=data.get('description', '')
      Lesson.unit=data.get('unit', '')
      Lesson.public=data.get('public', True)
      Lesson.save()
      return Lesson
  </code></pre>
  
  <p>And here is my view:</p>
  
  <pre><code>from django.shortcuts import render
  from django.http import HttpResponseRedirect
  from forms import CreateLesson
  
  def Create_Lesson(request):
      if request.method == 'POST': # If the form has been submitted...
          form = CreateLesson(request.POST) # A form bound to the POST data
          if form.is_valid(): # All validation rules pass
              form.save()
              return HttpResponseRedirect('/create/') # Redirect after POST
      else:
          form = CreateLesson() # An unbound form
  
      return render(request, 'create_lesson/new_ideas.html', {
          'form': form,
      })
  </code></pre>