title: How to get path from html5 input field file object for phonegap
body: <p>How do you get a path from a file object which is returned from an html5 input field? </p>
  
  <p>Basically the phonegap app is setup to go online and download a sound file from a thirdparty website, then browse to the downloaded file and move it to the local directory. (short &lt; 1 sec sound files). </p>
  
  <p>The problem is that file objects attribute .fullPath is undefined. and getFile takes a path input, not an [object File] input. </p>
  
  <p>From the following code:</p>
  
  <pre><code>&lt;input style="opacity:0;" type="file" name="soundInput" id="soundInput"/&gt;
  
  &lt;script type="text/javascript" charset="utf-8"&gt;
      var soundInput = document.getElementById('soundInput');
      soundInput.addEventListener('change', function(){handleFileSelect(type);}, false);
      soundInput.click();
  
      function handleFileSelect() {
          var file = this.files[0]; // FileList object
          var type = isThumpy;
  
          alert("file = " + file.name + "\n full path = " + file.fullPath);
  
          window.requestFileSystem(LocalFileSystem.PERSISTENT, 0, function(fs) {
              gotFS(fs,file,type);
          }, fail);
      }
  
      function fail(error) {
          alert("error " + error.code);
      }
  
      function gotFS(fileSystem, file, type) {
          alert("got filesystem");
          var flags = {create: false, exclusive: false};
          fileSystem.root.getFile(file, flags, function(fe){
              gotFileEntry(type,fe);
          },fail);
      }
  
      function gotFileEntry(type, fileEntry) {
          alert("got fileEntry");
          fileEntry.copyTo(path, function(fe){successfulCopy(type, fe);}, fail);
      }
  
      function successfulCopy(type, fileEntry) {
          alert("copy success");
          setSoundByUri(type, fileEntry.name)
      }
  &lt;/script&gt;
  </code></pre>
  
  <p>It doesn't get past "got filesystem", and it doesn't throw an error ("error " + error.code). Please help.</p>