title: how to view the blob image from database
body: <p>I want to retrieve the image from the database but its not work 
  php code</p>
  
  <pre><code>&lt;?php 
  $DB_HOST = 'localhost';
  $DB_USER = 'root';
  $DB_PASSWORD = '';
  $DB_DATABASE = 'capturemoment';
  
  $con = mysql_connect($DB_HOST, $DB_USER, $DB_PASSWORD);
  if(!$con) {
      die('Failed to connect to server: ' . mysql_error());
  }
  
  $db = mysql_select_db($DB_DATABASE);
  if(!$db) {
      die("Unable to select database");
  }
  if(isset($_GET['id'])){
      $id= mysql_real_escape_string($_GET['id']);
      $query=mysql_query("SELECT * FROM 'artical' WHERE 'artical_id'=$id");
      while ($row =mysql_fetch_assoc($query))
      {
           $imageData=$row["articale_image"]; 
      }
      header("content-type: image/jpg");
      echo $imageData;
  }
  else {echo "Error!";}
  ?&gt;
  </code></pre>
  
  <p>the php code that call the first code to view the image dynamic </p>
  
  <pre><code>&lt;img src="image.php?id=1" alt="imge (Phottix Mitros Flash for Canon)" style="width:65%;height:100%; border:1px solid #E6E6E6; align:center;"&gt;&lt;/a&gt;
  </code></pre>