Re: [thenetgirl] Faq split in columns
Hi there,
You won't want to duplicate the code, you'll only put it in there once. What it basically says is "After the 4th entry, print this other code. Then keep going."
That "other code" should be whatever you need to separate the two columns, that's the bit you'll want to experiment on.
For example, if you had a simple two column table like this:
<table>
<tr>
<td>
Column 1
</td>
<td>
Column 2
</td>
</tr>
</table>
....you'd turn that into this:
<table>
<tr>
<td>
<?php $count = 0 ?> <?php foreach ($faqRecords as $record): ?>
<b> <?php echo $record['question'] ?></b><br/>
<?php echo $record['answer'] ?><br/>
<?php if ($count++ == 4): ?>
</td><td> <?php endif ?>
</td>
</tr>
</table>
Does that make sense? :)
Donna
--
support@interactivetools.com