I know this is an easy problem to fix, but being a newbie, I don't know where else to look...
I want to store an HTML img src tag as a variable, that way if there is no information, the image doesn't show up...
Here is the code where the variable is set...
$image = "<img src="/images/apartments/thumb/$id.gif" alt="" height="48" width="64" border="0">";
I'm pretty sure php doesn't like some of the HTML characters in the tag, and that there is a way to identify them as HTML characters...
I'm just not sure how...
Can someone show me...?
Thanks!!!
If it helps I'm using a statement like this with it...
if (empty($id))
{
$image = "";
}
else
{
$image = "<img src="/images/apartments/thumb/$id.gif" alt="" height="48" width="64" border="0">";
}