Question: How to add images to JQuery autocomplete which also fills hidden data inputs?

Answer: 
I would suggest checking out [Sameer's answer to this for Swift 2.0, just a few months back.](https://stackoverflow.com/a/33228074/4851799) Works perfectly with Swift 2.0.

```
let sess = AVAudioSession.sharedInstance()
if sess.otherAudioPlaying {
    _ = try? sess.setCategory(AVAudioSessionCategoryAmbient, withOptions: []) //
    _ = try? sess.setActive(true, withOptions: [])
}

```
Xcode 10.3  

Swift 4.2  

Tested in iPhoneX (12.2), iPhone5s(11.0.3)

Functionality -> Play audio in silent mode + with other application audio.

Here is the code,

```
private func setupAudioSession() {
        //enable other applications music to play while quizView
        let options = AVAudioSession.CategoryOptions.mixWithOthers
        let mode = AVAudioSession.Mode.default
        let category = AVAudioSession.Category.playback
        try? AVAudioSession.sharedInstance().setCategory(category, mode: mode, options: options)
        //---------------------------------------------------------------------------------
        try? AVAudioSession.sharedInstance().setActive(true)
    }

```

I will suggest you to set this function in AppDelegate -> didFinishLaunchingWithOptions....