I have another problem. Lets say I want to display news but only have it display 10 or less which would be the most current news. Would I put a for statment in their or what. Here is the code I have to display the news. Thanks in advance for any help given.
$sql= "SELECT * FROM news ORDER BY newsid";
$result =@($sql, $connection) or die("Couldnt excecute query.");
while ($row = mysql_fetch_array($result)) {
$title =$row['title'];
$image =$row['image'];
$news =$row['news'];
$date =$row['date'];
$id =$row['newsid'];
if ($image) {
$image1= "$image";
} else {
$image1= "gen_1x1_transparent.gif";
}
$display_text .="<table border=0 cellpadding=0 cellspacing=0 align=center width='372'>
<tr>
<td class='newstitle'> $title </td>
</tr>
<tr>
<td><img src='images/gen_1x1_transparent.gif' width='30' height='1'>$news</td>
<td width='118'><img src='images/$image1'><br></td>
</tr>
<tr>
<td class='date' align=right>$date</td>
</tr>
</table >";
}