cdog1912 Posted December 22, 2008 Share Posted December 22, 2008 When i run this code all i get is a blank image window. can you help? This is the code: <?php include 'config.php'; include 'opendb.php'; $_get['content']; $query = "SELECT content FROM images"; $result = mysql_query($query); $row = "mysql_fetch_array('$result'))"; $img = $row['content']; { echo "<img src='?$content?'>"; } include 'closedb.php'; ?> Any help would be great thanks Quote Link to comment https://forums.phpfreaks.com/topic/138003-help-needed-to-display-images-from-mysql-database/ Share on other sites More sharing options...
Adam Posted December 22, 2008 Share Posted December 22, 2008 <?php include 'config.php'; include 'opendb.php'; $query = "SELECT content FROM images"; $result = mysql_query($query); while ($row = mysql_fetch_array($result)) { echo '<img src="' .$row['content']. '" />'; } include 'closedb.php'; ?> A Quote Link to comment https://forums.phpfreaks.com/topic/138003-help-needed-to-display-images-from-mysql-database/#findComment-721278 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.