Skip to content
This repository was archived by the owner on May 4, 2022. It is now read-only.
This repository was archived by the owner on May 4, 2022. It is now read-only.

Ionic FilePath not working, how to get the file path for Android 11 #1144

Description

@Shahrukh-cyber

I'm submitting a ... (check one with "x")
[x] bug report

this.androidFileChooser
.open({ mime: 'application/pdf' })
.then((file) => {
This gives me this response : "content://com.android.providers.downloads.documents/document/11654".

The problem is that I need to get the reallocation of the file to convert it to base 64 and send it with a POST request to the client server.
So before all these problems, I was using Android File Path from Ionic : https://ionicframework.com/docs/native/file-path

this.filePath.resolveNativePath(file).then((filePath) => {
And I was receiving file:///storage/emulated/0/Download/pdffile.pdf
Using this, I could transform it in base64 and everything worked well.

Now, it returns me nothing for Android 11. So All the process can’t work if I don’t have this filepath.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions