Hi, Just do a test on the result of the image URL field, and if the field value is "null" (or ""), change the field to a default image URL...
<? if($myrow["image_url"] == "" or $myrow["image_url"] == "null") { $myrow["image_url"] = "images/default_image.gif"; } echo "<IMG SRC=\"".$myrow["image_url"]."\">"; ?> Justin French -------------------- Creative Director http://Indent.com.au -------------------- on 28/03/02 2:32 PM, Chuck "PUP" Payne ([EMAIL PROTECTED]) wrote: > I am wanting to know if I can use null to call up an image? I am writing a > page that talks to calls to a database for cars. There a field where calls > on photo names, but if someone doesn't have a photo. Mysql puts null, I want > to be able to use that null to call an image. > > > ---------------------------- > | Chuck Payne | > | Magi Design and Support | > | www.magidesign.com | > | [EMAIL PROTECTED] | > ---------------------------- > > BeOS, Macintosh 68K, Classic, and OS X, Linux Support. > Web Design you can afford. > > "Never be bullied into silence. Never allow yourself to be made a victim. > Accept no one's definition of your life; define yourself."- Harvey Fierstein > > -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php