both 2 options link to display images
Dear all
+ In my code to display image using javascript as bellow
+ I have 2 options include: year (2010, 2011,..) and month (Jan, Feb,..)
It mean we click on 2 options allow to display image, respectively.
But in my code only allow link 1 option is month (year option is denied)
I'd like to link both options
Please tell me repair
Thank you
My code:
<script language="javascript">
function showimage()
{
if(!document.images)
return
document.images.pictures.src=
document.mygallery.picture.options[document.mygallery.picture.selectedIndex].value
}
</script>
<table width="1000" height="1000" border="3" cellpadding="0" cellspacing="0">
<tr>
<td style="background-color:#FFD700">
<form name="mygallery">
<p align="center">
<select name="picture" onChange="showimage()">
<option selected value="prob_Jan_2010.gif">Jan</option>
<option value="prob_Feb_2010.gif">Feb</option>
<option value="prob_Mar_2010.gif">Mar</option>
</select>
</p>
</form>
</td>
<td style="background-color:#FFD700">
<form action="">
<p align="center">
<select>
<option value="2011">2011</option>
<option value="2010">2010</option>
</select>
</p>
</form>
</td>
<td style="background-color:#FFD700">
<script type="text/javascript">
document.write("Tropical Cyclones")
</script>
</td>
</tr>
<tr>
<td colspan="3">
<p align="center"><img src="prob_Jan_2010.gif" name="pictures" width="900" height="800"/></p>
</td>
</tr>
</table>
Thread Information
Users Browsing this Thread
There are currently 1 users browsing this thread. (0 members and 1 guests)
Tags for this Thread
Posting Permissions
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
Forum Rules
Bookmarks