title: How can I add custom image to typeahead drop-down menu?
body: <p>The drop-down is populated from a remote table which also contains the url of the corresponding image. I am using typeahead 0.9.3. What method can be used to add custom images to the autocomplete?</p>
  
  <pre><code>&lt;?php
  
  $dbh = new PDO('mysql:host=localhost;dbname=****', 'root', '*****');
  
  $query ='%'.$_GET['query'].'%';
  
  $stmt = $dbh-&gt;prepare("SELECT event FROM events WHERE event LIKE :query");
  
  $stmt-&gt;bindParam(':query', $query, PDO::PARAM_STR);
  $stmt-&gt;execute();
  
  $results = array();
  
  foreach ($stmt-&gt;fetchAll(PDO::FETCH_COLUMN) as $row) {
      $results[] = $row;
  }
  
  echo json_encode($results);
  
  ?&gt;
  </code></pre>