danny770
January 31st, 2006, 05:18 AM
I have an image (component diagram) which I've sectioned in order to make individual components clickable. However, I'd like to extend this so that an idividual component's area becomes highlighted when the mouse is hovered over it. Is it possible to do this in Javascript, or another language? My code is as follows:
<html>
<head>
<title>Image Map Popup Demonstration</title>
<script language="JavaScript"><!--
function P(url,h,w) { // (url,height,width)
var p = "height=" + h + ",width=" + w + ",scrollbars=yes";
window.open(url,"",p);
} // -->
</script>
</head>
<body bgcolor="#ffffff" text="#333333">
<p>
<IMG align="centre" SRC="linux.bmp" HEIGHT="1002" WIDTH="1447" usemap="#linux.bmp" border="0">
<noscript>
<p>
I'm sorry, your browser must be JavaScript enabled to participate in the
popup window demonstration. Depending on your browser, you may be able
to turn your JavaScript off and on via a preferences menu.
</noscript>
<p>
<map name="linux.bmp">
<area shape="rect" coords="77,133,104,780"
href="javascript:P('test.htm',200,333)" alt="POSIX API">
<area shape="rect" coords="113,133,140,780"
href="javascript:P('test.htm',200,333)" alt="Logging">
<area shape="rect" coords="190,209,234,228"
href="javascript:P('test.htm',200,333)" alt="APC">
<area shape="rect" coords="190,239,234,258"
href="javascript:P('test.htm',200,333)" alt="WC">
<area shape="rect" coords="190,269,234,288"
href="javascript:P('test.htm',200,333)" alt="CLM">
<area shape="rect" coords="190,299,234,318"
href="javascript:P('test.htm',200,333)" alt="TMG">
</map>
</body>
</html>
Thanks in advance! :)
<html>
<head>
<title>Image Map Popup Demonstration</title>
<script language="JavaScript"><!--
function P(url,h,w) { // (url,height,width)
var p = "height=" + h + ",width=" + w + ",scrollbars=yes";
window.open(url,"",p);
} // -->
</script>
</head>
<body bgcolor="#ffffff" text="#333333">
<p>
<IMG align="centre" SRC="linux.bmp" HEIGHT="1002" WIDTH="1447" usemap="#linux.bmp" border="0">
<noscript>
<p>
I'm sorry, your browser must be JavaScript enabled to participate in the
popup window demonstration. Depending on your browser, you may be able
to turn your JavaScript off and on via a preferences menu.
</noscript>
<p>
<map name="linux.bmp">
<area shape="rect" coords="77,133,104,780"
href="javascript:P('test.htm',200,333)" alt="POSIX API">
<area shape="rect" coords="113,133,140,780"
href="javascript:P('test.htm',200,333)" alt="Logging">
<area shape="rect" coords="190,209,234,228"
href="javascript:P('test.htm',200,333)" alt="APC">
<area shape="rect" coords="190,239,234,258"
href="javascript:P('test.htm',200,333)" alt="WC">
<area shape="rect" coords="190,269,234,288"
href="javascript:P('test.htm',200,333)" alt="CLM">
<area shape="rect" coords="190,299,234,318"
href="javascript:P('test.htm',200,333)" alt="TMG">
</map>
</body>
</html>
Thanks in advance! :)