aprestong
08-22-2006, 08:29 PM
Hi everyone-
I am using FileMaker as a database and trying to create a table to display three columns of books on a website.
I am using php and a foreach() statement.
I imagine that in order to have three columns (instead of one) I need to do some sort of nested loop - but I can't seem to wrap my head around it.
Here is my code I'm using:
<?php
foreach( $lookupResult['data'] as $key => $searchData ){
?>
<table width="33%" border="1" cellpadding="6">
<tr>
<td width="106" height="167">
<img src="FX/image_proxy.php?FXimage=<? echo vignereEncryptURL($searchData['Cover'][0]); ?>"> </tr>
<tr>
<td height="212"><pre><b><?php echo $searchData['Title'][0];
?></b></pre>
<pre><?php echo $searchData['Contact'][0];
?></pre></td>
</tr>
</table>
<?php
echo '<br>';
echo '<br>';
}
?>
Does anyone have a suggestion for me that would allow me to display this in three columns instead of one?
I am using FileMaker as a database and trying to create a table to display three columns of books on a website.
I am using php and a foreach() statement.
I imagine that in order to have three columns (instead of one) I need to do some sort of nested loop - but I can't seem to wrap my head around it.
Here is my code I'm using:
<?php
foreach( $lookupResult['data'] as $key => $searchData ){
?>
<table width="33%" border="1" cellpadding="6">
<tr>
<td width="106" height="167">
<img src="FX/image_proxy.php?FXimage=<? echo vignereEncryptURL($searchData['Cover'][0]); ?>"> </tr>
<tr>
<td height="212"><pre><b><?php echo $searchData['Title'][0];
?></b></pre>
<pre><?php echo $searchData['Contact'][0];
?></pre></td>
</tr>
</table>
<?php
echo '<br>';
echo '<br>';
}
?>
Does anyone have a suggestion for me that would allow me to display this in three columns instead of one?