Hey can anyone tell my why this code isn't working. The table loads, all the data come from the database in the 'foreach' PHP loop just fine but the 3 pieces of data for 'code' 'summer_program' and 'school_organization' don't load.
I just can't work out why.
Cheers
I just can't work out why.
Cheers
<table>
<tr>
<td>
<strong>Code:</strong><?php $detail = $form->data['code']; ?><br/>
<strong>Program:</strong><?php $detail = $form->data['summer_program']; ?> <strong>School: </strong><?php $detail = $form->data['school_organization'];?>
</td>
</tr>
</table>
<table width="590px" style="text-align: left;" >
<tr>
<th width="20%"><strong>Surname:</strong></th>
<th width="20%"><strong>First Name:</strong></th>
<th width="20%"><strong>Passport/ID:</strong></th>
<th width="20%"><strong>Birthday:</strong></th>
<th width="20%"><strong>Phone:</strong></th>
</tr>
<?php
foreach ($form->data['ProgramList'] as $detail):
?>
<tr>
<td><?php echo $detail['surname']; ?></td>
<td><?php echo $detail['given_name']; ?></td>
<td><?php echo $detail['passport']; ?></td>
<td><?php echo $detail['phone']; ?></td>
<td><?php echo $detail['bd_day'] ?> <?php echo $detail['bd_month'] ?> <?php echo $detail['bd_year']; ?></td>
</tr>
<?php
endforeach;
?>
</table>