Home > OS >  is permission needed when choosing image from gallery on android?
is permission needed when choosing image from gallery on android?

Time:06-12

i'm currently making an apps that can upload choosen image from gallery to mysql database via php, but now i'm in confuse because i read on android 11 or above you need a storage access permission. So, is permission to access the storage is needed when you only need to choose image from gallery?

Thank you

CodePudding user response:

Yes, your app must have the permission <uses-permission android:name="android.permission.READ_EXTERNAL_STORAGE"/> and you have to prompt the user to accept that permission to be able to pick files from gallery

CodePudding user response:

No you do not need any permission using ACTION_PICK, ACTION_GET_CONTENT or ACTION_OPEN_DOCUMENT.

  • Related