Table Background
Posted: Mon May 31, 2004 12:58 pm
I am trying to create a news script that will have a image, with text over it for the title. The image does not work.
How come the image doesnt display in the background of a cell?
Code: Select all
<?PHP
$db = mysql_connect("blah");
mysql_select_db("seven" , $db) or die("Couldn't open $db: ".mysql_error());
$query = "SELECT * FROM sevennews";
$result=mysql_query($query);
while ($row = mysql_fetch_array($result)){
?><td width="330" height="13" background="bar_dark.gif" valign="top">
<p style="margin-left: 45; margin-top: 0; margin-bottom: 0"><b><font color="#000000">
<?
echo $row['date'];
echo ' - ';
echo $row['description'];
echo '</font></b></p>
</td>
</tr>
<tr>
<td width="330" height="52" valign="top">
<p style="text-indent: 20">';
echo $row['story'];
echo ' </tr>
<tr>
<td width="330" height="8" valign="middle" align="right">
<p style="text-indent: 0; margin-left: 0; margin-right: 25; margin-top: 0; margin-bottom: 0"><b>';
echo $row['author'];
echo ' </b></td>
</tr>';
}
?>