Hello everyone!
I’d like to know what code I need to let my pilots choose their aircraft in the schedule briefing because the calculation of fuel depends on the aircraft. I’ve tried that but it’s not good!
<dd>
<select name=“aircraft” id=“aircraft”>
<option value=“”>Si l’appareil avec lequel vous avez volé n’est pas dans la liste cliquez sur AUTRE.</option>
<?php
foreach($allaircraft as $aircraft)
{
$sel = ($_POST[‘aircraft’] == $aircraft->name || $bid->registration == $aircraft->registration)?‘selected’:‘’;
echo ‘<option value="’.$aircraft->id.‘" ‘.$sel.’>’.$aircraft->name.’ - ‘.$aircraft->registration.’</option>';
}
?>
</select>
</dd>
Thank you for your help!