Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

In iOS, not able to open .epub and .mobi file using file opener plugin #223

Open
Topiya opened this issue Aug 14, 2018 · 8 comments
Open

Comments

@Topiya
Copy link

Topiya commented Aug 14, 2018

Hello,

I want to open .epub and .mobi files using file-opener plugin of Ionic-cordova in iOS app. But while doing this I am getting below error.

can not handle uti

Can anyone please help me to solve this error?

@godoyrw
Copy link

godoyrw commented Aug 15, 2018

@Topiya
Copy link
Author

Topiya commented Aug 16, 2018

@godoyrw Can you please recheck the given URL because it is not working.

@godoyrw
Copy link

godoyrw commented Aug 16, 2018

It's ok now! Sorry!

@shnist
Copy link
Collaborator

shnist commented Dec 11, 2018

@Topiya did the suggestions in that issue resolve your issue?

@Topiya
Copy link
Author

Topiya commented Dec 12, 2018

@shnist No, It didn't solve my issue. Is there any other workaround for this issue?

@shnist shnist added the bug label Dec 12, 2018
@shnist
Copy link
Collaborator

shnist commented Dec 13, 2018

@Topiya can you provide a code snippet from your project? This will help diagnose the issue. One thing you can try, if you haven't done so already, is to try and provide the relevant MIME type (https://developer.mozilla.org/en-US/docs/Web/HTTP/Basics_of_HTTP/MIME_types/Complete_list_of_MIME_types). So for example, an .epub file would look something like:

cordova.plugins.fileOpener2.open('file.epub',  'application/epub+zip', {  error : function(){ },   success : function(){ } });

@shnist shnist added the ios label Dec 21, 2018
@prasadpandari
Copy link

Anyone able to find a solution for this. I have same issue.
cordova.plugins.fileOpener2.open(
dirEntry.nativeURL + fileName,
mimetype,
{
error: (e) => {
console.log(Error status: ${e.status} - Error message: ${e.message});
},
success: () => {
})

Iam getting "Error status: 9 - Error message: Could not handle UTI

@Pawel86400
Copy link

Any idea what can cause this error and how to solve it?

My MIME type is application/pdf.
Surprisingly only 1 user out of many is experiencing this issue on iPhone 7 Plus.

Unfortunately I'm not able to reproduce it on other devices or in the simulator.

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

No branches or pull requests

5 participants