This is Interesting: Free Magazines for Graphics designers and webmasters  


Home > Archive > Dreamweaver > April 2005 > retrieving images from mysql database problem.....





You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

Author retrieving images from mysql database problem.....
hub_s

2005-04-29, 7:20 pm

Hi,
I've created a search for my site where user can view a list of businesses
under the selected category.
Now the problem is for some of my customers i have a logo and others i don't.
When i include the logo field in the recordset the logo appears ok for the
businesses that asked for one but when i choose a business that doesn't have a
logo the empty image box with the x in the top corner appears where the logo is
designed to appear.
Is there any way i can design this so that only the logo will appear for the
records i choose and for the rest, just a blank space with on 'empty cell'
appearing.

They are phps designed in dreamweaver using mysql database.

thanks
hub_s

-Rb

2005-04-29, 7:21 pm


"hub_s" <webforumsuser@macromedia.com> wrote in message
news:d4thht$j0h$1@forums.macromedia.com...
> Hi,
> I've created a search for my site where user can view a list of businesses
> under the selected category.
> Now the problem is for some of my customers i have a logo and others i
> don't.
> When i include the logo field in the recordset the logo appears ok for the
> businesses that asked for one but when i choose a business that doesn't have
> a
> logo the empty image box with the x in the top corner appears where the logo
> is
> designed to appear.
> Is there any way i can design this so that only the logo will appear for the
> records i choose and for the rest, just a blank space with on 'empty cell'
> appearing.
>
> They are phps designed in dreamweaver using mysql database.
>
> thanks
> hub_s
>


If I am understanding your question, you would need to wrap
an if statement around the display of the logo.

<td>
<?php
if(isset($row['logo']))
{
echo $row['logo'];
}else {
echo" ";
}
?>
</td>

HTH

-Rb

Sponsored Links


Copyright 2003 - 2008 forum4designers.com  Software forum  Computer Hardware reviews