Guest User

Untitled

a guest
Aug 19th, 2018
83
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.61 KB | None | 0 0
  1. HTML/Javascript Overlaying Images on Region Mouseovers
  2. <script type="text/javascript">
  3. function area1_mouseover() {
  4. document.getElementById('image2').style.visibility = 'visible';
  5. }
  6. function area1_mouseout() {
  7. document.getElementById('image2').style.visibility = 'hidden';
  8. }
  9. </script>
  10. <img src="image2.png" id="image2" style="position: absolute; visibility: hidden; z-index: 2;" usemap="#my_map" />
  11. <img src="image1.png" id="image1" usemap="#my_map" />
  12. <map name="my_map">
  13. <area shape="rect" coords="0,0,100,100" onmouseover="area1_mouseover();" onmouseout="area1_mouseout();" />
  14. </map>
Add Comment
Please, Sign In to add comment