title: how to simply handle the request with python
body: <p>I'm trying to do some testing in html5 uploading files,here is the simple html codes:</p>
  
  <pre>
  var fileInput=document.getElementById("the-file")
  
  fileInput.addEventListener('change',function(e){
  
  var file=e.target.files[0]
  
  var xhr=new XMLHttpRequest()
  
  xhr.open('post','upload/<strong>handlecode</strong>',true)
  
  xhr.send(file)
  }
  </pre>
  
  <p>I use 
  <code>python -m SimpleHTTPServer </code>
  to test this section
  the problem is that I DON'T know how to write the <strong>handlecode</strong> file to handle
  the http request,<br/></p>
  
  <p>the <strong>handlecode</strong> file only save the file in the upload floder,no more complicated tasks<br/></p>
  
  <p>Although I don'k know whether testing in this way is right or not<br/></p>
  
  <p>Can someone give some hints
  or offer me the right way to test ,Thank you all very much!</p>