Closed georgegoudie closed 5 years ago
hi @georgegoudie, thanks for reporting this. I will take a look.
can you please send me a link to the PDF you are downloading and opening through this plugin? My gut tells me that this is not an issue with this plugin because it just hands off to the relevant native application (i.e. this plugin does not control the display of the PDF viewer on iOS), but I would like to double check if I can replicate what you're seeing.
Thanks for getting back to me, here is the pdf. I have noticed it on another pdf which suggests it isn't the pdf but definitely worth checking Green-guide-lakes.pdf
Unfortunately I can't replicate this. The done button appears in English on my local iOS simulator.
Are you able to provide a cope snippet of what you're doing?
No problem;
fileTransfer.download(url, this.file.dataDirectory + file.Url).then((entry) => { this.fileOpener.open(this.file.dataDirectory + file.Url, file.MimeType) .then(() => console.log('File is opened')) .catch(e => this.showToast('Could not open file')); }, (error) => { this.showToast('Could not download file, check your internet connection') });
Hi @shnist did you have any luck with this?
hi @georgegoudie, unfortunately I couldn't replicate this, but one thing i've noticed is that you're not using the file entry that is being downloaded? You could try something like this:
fileTransfer.download(url, this.file.dataDirectory + file.Url).then((entry) => {
this.fileOpener.open(entry.toUrl(), 'application/pdf')
.then(() => console.log('File is opened'))
.catch(e => this.showToast('Could not open file'));
}, (error) => {
this.showToast('Could not download file, check your internet connection')
});
I've assumed that you're only downloading pdfs, so I've hardcoded the MIMETYPE.
This was the culprit! https://github.com/mapsplugin/cordova-plugin-googlemaps/issues/2116
Thanks for looking into it for me
what an odd bug! thanks for letting me know the reason.
Using latest version, chinese characters being displayed in ios, phone langauge is set to English![img-5523](https://user-images.githubusercontent.com/4190118/52952103-81039380-337b-11e9-96ee-ffc5bbe48dc1.jpg)