Hi I'm really new to this and i'm trying to get data from an array for a drop down box, here is what I have tried but all that shows in the box is the word array. Anyone able to help?
</form>
Hi I'm really new to this and i'm trying to get data from an array for a drop down box, here is what I have tried but all that shows in the box is the word array. Anyone able to help?
</form>
You need to loop through the array not just print it.
<select name="newspaper">
<?php foreach($newspaper as $index => $item) { ?>
<option value="<?php echo $index; ?>"><?php echo $item; ?></option>
<?php } ?>
</select>
You should definitely look up arrays and read more about them.