1

Hi seen many tutorial but couldn't find the right workable answer. I need to play audio and video file from my webservice, for this I want to download the file and play it in the app, seen tutorial for avPlayer nothing workable. Please provide link or guide how to do this.

Ali Raza
  • 2,796
  • 1
  • 20
  • 24

1 Answers1

0

Use MPMoviePlayer, as this can open network streams and despite the name works with audio. The only thing is this pops up the modal player with controls.

First Download the network file using NSURLConnection and store it locally, then use AVAudioPlayer to play the local file.

Codesen
  • 7,724
  • 5
  • 29
  • 31