Jump to content

display images with php mysql


Recommended Posts

i can see characters instead of image using below code. i used blob data type for storing images in mysql.

 

// Performing SQL query

$query = 'SELECT Image FROM tableImages';

$result = mysql_query($query) or die('Query failed: ' . mysql_error());

 

// Printing results in HTML

 

list($Image) = mysql_fetch_array($result);

 

 

echo $Image; //print or return image

Link to comment
Share on other sites

Guest
This topic is now closed to further replies.
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.