<?php
$con = mysql_connect("localhost","root","" );
mysql_select_db("test",$con);
$sql="select image from image";
$res=mysql_query($sql) or die(mysql_error());
$i=1;
while($i < mysql_num_rows($res))
{
$image_id[$i] = mysql_result($res, $i);
echo "<img src=\"".$image_id[$i]."\">";
$i++;
}
?>
I'm using this code to display the image from mysql
but images are shown like this
M¢—‡¤6n幆J1³ŒªÌF·æFLùp1 `‘ã:ÃDVNÒ–¢QSgWñg€?´‘íx3²ûEùÝ ô.l%·ËìÈŒÿAzH'óÀËË€XƒÍ«L²GçÚ›9ást¸°äŒëŸ]˜¦21ŒÖ|¸E^®ÏJOXX&æàߣéü6bêæ¬Öò7aúQ¡·÷9;Ó-ˆ )ôdx¹cüÖlÒ'j( q1ÌnéW4Ó÷dÇå©uF
Any body please help me whats the error in that code:?: