This is what I want to do.
Normally I would insert an image with
<img src = “picture.jpg” height=”300″ width=”300″>
and add text from a variable with
<script language=”javascript”>document.write (‘some text’);</script>
I have a ‘list’ of names and pictures in an array of arrays like:
var people =[
[‘PHILIP ADDISON’,’PAddison2a.jpg’],
[‘DAVID ASBURY’,’DAsbury2a.jpg’],
[‘J ASHTON’,’oldbadge.jpg’],
[‘MICHAEL AZURDIA’,’MAzurdia.jpg’],
[‘IAN BAKEWELL’,’IBakewell2b.jpg’],
[‘BERNARD BARRY’,’BernardBarry2b.jpg’]
I want to insert a name and associated picture into a web page.
I can insert the name like this
<script language=”javascript”>document.write (people[8][0]);</script>
I want to insert the picture in a similar way like
<img src = “. . .people[8][1]” height=”300″ width=”300″>
But I can’t figure out how to do it.
Any hints would be appreciated.