title: Cordova Move File using the file url
body: <p>How can I move a file using the URL I get from the Camera?</p>
  
  <p>neither successCallback nor errorCallback is called by the function moveTo. Can anyone tell me what I am doing wrong and what a possible solution looks like?</p>
  
  <pre><code>function successCallback(entry) {
      console.log("New Path: " + entry.fullPath);
      alert("Success. New Path: " + entry.fullPath);
  }
  
  function errorCallback(error) {
      console.log("Error:" + error.code)
      alert(error.code);
  }
  
  // fileUri = file:///emu/0/android/cache/something.jpg
  function moveFile(fileUri) {
      newFileUri  = cordova.file.dataDirectory + "images/";
      oldFileUri  = fileUri;
      fileExt     = "." + oldFileUri.split('.').pop();
  
      newFileName = guid("car") + fileExt;
  
      // move the file to a new directory and rename it
      fileUri.moveTo(cordova.file.dataDirectory, newFileName, successCallback, errorCallback);
  }
  </code></pre>
  
  <p>I am using Cordova version 4.1.2 Also installed the Cordova File Plugin</p>