title: fetch the path of an image stored in gallery after camera capture
body: <p>I am opening camera using following code</p>
  
  <pre><code>Intent captureImageIntent = new Intent(android.provider.MediaStore.ACTION_IMAGE_CAPTURE);
  
  cordova.setActivityResultCallback(this);
  
  cordova.getActivity().startActivityForResult(captureImageIntent,RESULT_CAPTURE_IMAGE);
  </code></pre>
  
  <p>and inside <code>onActivityResult</code> i am trying to get the <code>path of the image</code> that is stored in gallery , so that i can return it back to the web page.</p>
  
  <p>here what i have tried so far </p>
  
  <pre><code>Uri uri = intent.getData(); // doesnt work 
  </code></pre>
  
  <p>i tried to use <code>MediaStore.EXTRA_OUTPUT</code> but in that case i am getting null intent.</p>
  
  <pre><code>captureImageIntent.putExtra(MediaStore.EXTRA_OUTPUT, mPhotoUri);
  </code></pre>
  
  <p>so can anyone tell me how can i fetch the path ?</p>
  
  <p>EDIT</p>
  
  <pre><code> String fileName = "temp.jpg";  
   contentValues values = new ContentValues();  
   values.put(MediaStore.Images.Media.TITLE, fileName); 
  
              Uri mPhotoUri = cordova.getActivity().getContentResolver().insert(MediaStore.Images.Media.EXTERNAL_CONTENT_URI, values);  
  </code></pre>