woodstock88
Programmer
Hello
i'm relatively new in javascript... I have a script that onmouseover an image map it displays another image on top.. what I have not being able to do correctly is the image that is display onmouseover when I click on it will display me a popup window... my code is the following:
<script language="javascript1.2" >
function hidePic(picID)
{
var pic = document.getElementById(picID).style
pic.display = (pic.display != 'block') ? "block" : "none"
}
function showPic(id,txt)
{ document.getElementById(id).innerHTML = txt
}
function mypopup()
{
mywin = window.open("imagenes/icon_play.gif","mywindow","status=0,resizable=0,width=350,height=250, directories=0")
} </script>
<body>
<div id="myPic"
style="position: absolute; width: 60px; height: 55px;
z-index: 1; left: 30px; top: 50px;
border: 0px; display: none;">
</div>
<img src="icon_play.gif" width="80" height="80" usemap="#pics" border="0"/>
<map name="pics">
<area shape="rect" coords="10,10,80,80" href="javascript: void(0)" onmouseover="hidePic('myPic');showPic('myPic',
'<img src = \'image\\icon.gif\'>');" onmouseout="hidePic('myPic');" onmousedown="mypopup();"/>
</map>
How I have it right now i know the onmousedown will work in the map image... how can i make it work in the image display onmouseover...
thanx![Smile :) :)](data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7)
<script language="javascript1.2" >
function hidePic(picID)
{
var pic = document.getElementById(picID).style
pic.display = (pic.display != 'block') ? "block" : "none"
}
function showPic(id,txt)
{ document.getElementById(id).innerHTML = txt
}
function mypopup()
{
mywin = window.open("imagenes/icon_play.gif","mywindow","status=0,resizable=0,width=350,height=250, directories=0")
} </script>
<body>
<div id="myPic"
style="position: absolute; width: 60px; height: 55px;
z-index: 1; left: 30px; top: 50px;
border: 0px; display: none;">
</div>
<img src="icon_play.gif" width="80" height="80" usemap="#pics" border="0"/>
<map name="pics">
<area shape="rect" coords="10,10,80,80" href="javascript: void(0)" onmouseover="hidePic('myPic');showPic('myPic',
'<img src = \'image\\icon.gif\'>');" onmouseout="hidePic('myPic');" onmousedown="mypopup();"/>
</map>
How I have it right now i know the onmousedown will work in the map image... how can i make it work in the image display onmouseover...
thanx