title: How to use $.post with django?
body: <p>How can I use the <code>jquery.post()</code> method in Django?</p>
  
  <p>This is what I am trying to do:</p>
  
  <pre><code>         var postdata={
                'username':$('#login-email').val(), 
                'password':$('#login-password').val()
           }
  
           $.post('/login/',postdata)
  </code></pre>
  
  <p>How do I CSRF protect this in django? Is there a way to add to the CSRF token to the post data?</p>