Redirect to view in other image folders using ImagePicker plugin in android (Ionic 3)

346 Views Asked by At

I am using the image picker plugin in my Ionic app. I want able to pick images from other folders from the gallery in android device. For Ios it is possible but for android I am getting this view. enter image description here

But I want user able to go to other folders and select images from it. Any help would be great.

1

There are 1 best solutions below

2
On

I supose you are using cordova plugin File. If you want select others routes, u can use the diferents directories provided by File. EJ:

this.file.applicationStorageDirectory
this.file.applicationDirectory
this.file.documentsDirectory

You have the complete list here https://github.com/apache/cordova-plugin-file
If you need more help, say to me.


to use if With Filepicker use a constant to set options:

const options = {
  title: 'Select Avatar',
  customButtons: [{ name: 'fb', title: 'Choose Photo from Facebook' }],
  storageOptions: {
    skipBackup: true,
    path: 'images',
  },
};

and send it to the picker:

ImagePicker.showImagePicker(options, (response) => {