arielfaur / ionic-audio

An audio player for Ionic 3 and Angular 4. Works with HTML 5 audio or native audio using Cordova Media plugin.
http://arielfaur.github.io/ionic-audio/2.0/index.html
MIT License
320 stars 163 forks source link

iOS Bug: Not able to play again #171

Closed mubasshir closed 6 years ago

mubasshir commented 6 years ago

Hi, I'm using this in Chat module where I've ChatPage, which loads ChatBubbleComponent. Inside ChatBubble, I've used your track code.

In iOS, its track plays once perfectly but when I try to play again, it gives me error code 4(media plugin used).

Even if I play another track, they won't work and give me same error.

CrispyFriedPig commented 6 years ago

Hi mubasshir, Maybe I meet the same issue like yours. Hope below infomation can help you. Did your audio src uses server url ? I geess there is something wrong when the audio plugin run on ios with server url. I tried to download the audio first, then give the local url to the audio src. At last, it works! Oh, I forget to tell you that you can download audio from server by the file transfer plugin, please see the below url: https://ionicframework.com/docs/native/file-transfer/

mubasshir commented 6 years ago

Hi, I'm using local files still doesn't work.

CrispyFriedPig commented 6 years ago

Hi mubasshir,

Sorry, I don't know your details. Make sure your code and related permission is right. Just try it with a simple demo reference to the official document first.

arielfaur commented 6 years ago

If you have a public link to your project maybe I can look at it. It is hard to tell otherwise.

mubasshir commented 6 years ago

I understand. I will try to make a public repo in days

As of now, I've to drop this and using Streaming Media Plugin