# Calling an image from database

**URL:** https://forum.kirupa.com/t/calling-an-image-from-database/226842
**Category:** Uncategorized
**Created:** [May 24, 2007, 2:37pm UTC](https://forum.kirupa.com/t/calling-an-image-from-database/226842 "2007-05-24T14:37:33Z")
**Posts on this page:** 1
**Page:** 1

<div class="post-metadata">

### Author: ![alexguz79](https://avatars.discourse-cdn.com/v4/letter/a/e274bd/32.png) [@alexguz79](https://forum.kirupa.com/u/alexguz79)
#### Post date: [May 24, 2007, 2:37pm UTC](https://forum.kirupa.com/t/calling-an-image-from-database/226842/1 "2007-05-24T14:37:33Z")

</div>

hey everybody…

i’m trying to call an image from my DDBB but nothing comes up… can anybody tell me what’s wrong with my code?

result show me data, but not the image, thanks

here’s the code

* * *

\<?php  
require\_once(‘config.php’);  
$sql = “SELECT \* FROM articulos ORDER BY ID DESC LIMIT 0,10”;  
$query = mysql\_query($sql);  
while ($row = mysql\_fetch\_array($query)){  
echo ‘\<p\> \<a href="articulo.php?id=’.$row[‘id’].’"\>’;  
echo $row[‘titulo’];  
echo ‘\</a\> \</p\>’;  
echo $row[‘subtitulo’];  
echo $row[img src="[‘imagen’]"];  
}  
?\>
