title: Getting an image url from sql database using php
body: <p>I'm trying to retrieve an image url from a database called flags in the image field to use.</p>
  
  <p>Where am I going wrong with this?</p>
  
  <pre><code>&lt;?php
      connect();
      $sql = ("SELECT image FROM members, flags WHERE members.member_id = '$_SESSION[id]' AND flags.id = members.country");
      $result = mysql_query($sql);
  ?&gt;
  &lt;div id="flag"&gt;
  &lt;img id="flag" src="$result" width="16px" height="11px"/&gt;
  </code></pre>