Image problem!
Posted: Sun Jul 04, 2004 4:50 pm
I am having a bit of problem with my database images. I posted a couple of days ago to see how I can get a row of 6 images if anyone remembers. Anyway the problem now is that its not showing the ID for the links. The code go's like:
You can see the line where I try to show the ID:
Regards
Joe
Code: Select all
while (true)
{
$row = mysql_fetch_assoc($result);
if ($row == false) break;
$images[] = $row['image'];
$ID = $row['ID'];
}
for($x = 0, $y = count($images); $x < $y; $x++)
{
if($x % 6 == 0)
echo '<tr>';
echo '<td><A href="viewtopic.php?ID="'.$ID.'"><img src="'.$images[$x].'" border=0 /></A></td> ';
if($x % 6 == 5)
echo '</tr>';
}
$y = ($y + 5) % 6;
if($y != 5)
echo '<td colspan=".($y+1)."> </td></tr>';Any help appreciated.echo '<td><A href="viewtopic.php?ID="'.$ID.'"><img src="'.$images[$x].'" border=0 /></A></td> ';
Regards
Joe