select php foreach select as option option value php echo option id ph

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
<select>
<?php
foreach ($select as $option):
?>
<option
value="<?php echo $option['id']; ?>"
<?php echo $account['option'] == $option['id'] ? 'selected' : ''; ?> >
<?php echo $option['title']; ?>
</option>
<?php
endforeach;
?>
</select>