Sorry if this is too obvious but I’m learning how to deal with arrays and I’m totally stuck, cannot go on :(
Having the following array:
$myarray: array =
0:array=
0:string=-
1:string=-
1:array=
0:string=AA1
1:string=Book title 1
2:string=Author 1
2:array=
0:string=AA2
1:string=Book title 2
2:string=Author2
.
.
I need to build a select in an html form filling it in this way:
<select id="bookTitles">
<option value="-" selected="selected">Select..</option>
<option value="AA1"> Book title 1</option>
<option value="AA2"> Book title 2</option>
.
.
</select>
How can I loop the $myarray
to do so?
Thanks a ton!