I would like to play a sound when someone click home button of iphone/ipad, e.g. when application goes in background.
I have already added "App plays audio" required background in my info.plist.
I am trying to play an audio file in applicationWillResignActive and applicationDidEnterBackground methods using AVAudioPlayer. But no success yet.
Any solution to this?