Show/Hide layers onMouseOver

  Mysticnas 10:05 28 Nov 05
Locked

Hi all,

Just wondering, can someone see anything wrong with this code:

area shape="rect" coords="75,583,243,700" onMouseOver="MM_showHideLayers('Layer3',','show')" onMouseOut="MM_showHideLayers('Layer3',','hide')">

  djinn 12:00 28 Nov 05

Change to this....

<area shape="rect" coords="75,583,243,700" href="javasript:;" onMouseOver="MM_showHideLayers('Layer3',','show')" onMouseOut="MM_showHideLayers('Layer3',','hide')">

HTH
Cheers

  Mysticnas 13:47 28 Nov 05

sorry.. didn't make a difference.

in the satus bar in the bottom of ie it says (error on page) with a little yellow warning triangle.

It works on another page. But not this one.

  djinn 16:32 28 Nov 05

Odd - try clicking in your area map - enter javascript:; in the link field, then hit F12.

The only bit you were missing (going from the code you posted) was a null link - the above really should work.

Can you post a link to a live page - if you don't get it working?

Cheers

  djinn 16:34 28 Nov 05

hehe - just noticed the spelling howler in my original code.......

replace javasript:; with javascript:;

HTH
Cheers

  Mysticnas 08:51 29 Nov 05

still didn't work. I can't provide a link because it sits on the intranet, but here's the whole page code:

(probably more readable by pasting into a notepad)

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"click here">
<html><!-- InstanceBegin template="/Templates/template_mpol.dwt" codeOutsideHTMLIsLocked="false" -->
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<!-- InstanceBeginEditable name="doctitle" -->
<title>Untitled Document</title>
<!-- InstanceEndEditable --><!-- InstanceBeginEditable name="head" -->

<!-- InstanceEndEditable -->
<style type="text/css">
<!--
.title {
font-family: Arial, Helvetica, sans-serif;
font-size: 18pt;
font-weight: bold;
color: #000000;
}
.body_text {
font-family: Arial, Helvetica, sans-serif;
font-size: 11pt;
font-style: normal;
color: #002967;
font-weight: normal;
border-top-width: 0px;
border-top-style: none;
border-top-color: #FFFFFF;
padding-top: 0px;
padding-right: 0px;
padding-bottom: 0px;
padding-left: 0px;
}
.header {
font-family: Arial, Helvetica, sans-serif;
font-size: 30pt;
font-weight: normal;
color: #FFFFFF;
background-image: url(images/new%20banners/banner3.jpg);
background-repeat: no-repeat;
background-position: left top;
background-attachment: fixed;
height: 85px;
vertical-align: baseline;
width: 565px;
font-style: normal;
line-height: normal;
text-align: left;
text-indent: 10px;
}
-->
</style>

  Mysticnas 08:53 29 Nov 05

<script language="JavaScript" type="text/JavaScript">
<!--
function MM_reloadPage(init) { //reloads the window if Nav4 resized
if (init==true) with (navigator) {if ((appName=="Netscape")&&(parseInt(appVersion)==4)) {
document.MM_pgW=innerWidth; document.MM_pgH=innerHeight; onresize=MM_reloadPage; }}
else if (innerWidth!=document.MM_pgW || innerHeight!=document.MM_pgH) location.reload();
}
MM_reloadPage(true);

<script language="JavaScript" type="text/JavaScript">
function MM_findObj(n, d) { //v4.01
var p,i,x; if(!d) d=document; if((p=n.indexOf("?"))>0&&parent.frames.length) {
d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);}
if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i<d.forms.length;i++) x=d.forms[i][n];
for(i=0;!x&&d.layers&&i<d.layers.length;i++) x=MM_findObj(n,d.layers[i].document);
if(!x && d.getElementById) x=d.getElementById(n); return x;
}

function MM_showHideLayers() { //v6.0
var i,p,v,obj,args=MM_showHideLayers.arguments;
for (i=0; i<(args.length-2); i+=3) if ((obj=MM_findObj(args[i]))!=null) { v=args[i+2];
if (obj.style) { obj=obj.style; v=(v=='show')?'visible':(v=='hide')?'hidden':v; }
obj.visibility=v; }
}

//-->
</script>
<style type="text/css">
<!--
.style7 {
font-size: 1px;
border-bottom-color: #E1F5FF;
border-color: #FFFFFF;
border-bottom-style: solid;
border-bottom-width: 1px;
}
.style8 {
font-family: Arial, Helvetica, sans-serif;
font-size: 10px;
color: #005FA9;
}
.style11 {font-size: 24px; color: #FFFFFF; }
body,td,th {
font-family: Verdana, Arial, Helvetica, sans-serif;
font-size: 10pt;
color: #FFFFFF;
border-top: 0;
border-top-color: #E1F5FF;
border-top-width: 0px;
border-color: #FFFFFF;
border-bottom-color: #E1F5FF;
border-bottom-style: solid;
border-bottom-width: 0px;
border-top-style: solid;
}
a:link {
color: #0052CC;
text-decoration: underline;
}
a:visited {
color: #0052CC;
text-decoration: underline;
}
a:hover {
color: #0052CC;
text-decoration: underline;
}
a:active {
color: #0052CC;
text-decoration: underline;
}
.style17 {color: #68ADDF}
.div_tag_1 {
border-top-width: 0px;
border-right-width: 0px;
border-bottom-width: 2px;
border-left-width: 0px;
border-top-color: #68ADDF;
border-right-color: #FFFFFF;
border-bottom-color: #E1F5FF;
border-left-color: #FFFFFF;
border-bottom-style: solid;
border-top-style: none;
font-size: 1px;
}
.header_text {
font-family: Arial, Helvetica, sans-serif;
font-size: 30pt;
font-weight: normal;
color: #FFFFFF;
background-image: none;
background-repeat: no-repeat;
background-position: left top;
background-attachment: fixed;
height: 85px;
vertical-align: baseline;
width: 565px;
font-style: normal;
line-height: normal;
text-align: left;
text-indent: 10px;
}
.style24 {font-size: 18px}
.side_bar {
font-family: Arial, Helvetica, sans-serif;
font-size: 11pt;
font-weight: normal;
color: #002967;
padding-left: 2px;
}
.a_link_2 {
color: #002967;
text-decoration: none;
font-size: 11px;
}

  Mysticnas 08:53 29 Nov 05

a:link {
color: #0052CC;
}
.main_menu_links {
color: #FFFFFF;
text-decoration: none;
}
a.main_menu_links:link {
font-family: Verdana, Arial, Helvetica, sans-serif;
font-size: 10pt;
color: #FFFFFF;
text-decoration: none;
}
a.main_menu_links:active {
font-family: Verdana, Arial, Helvetica, sans-serif;
font-size: 10pt;
color: #FFFFFF;
text-decoration: none;
}
a.main_menu_links:hover {
font-family: Verdana, Arial, Helvetica, sans-serif;
font-size: 10pt;
color: #FFFFFF;
text-decoration: none;
}
.side_bar_links {
font-family: Arial, Helvetica, sans-serif;
font-size: 11pt;
color: #FFFFFF;
text-decoration: none;
padding-left: 2px;
border-top: none;
border-right: none;
border-bottom: none;
border-left: none;
font-weight: bold;
}
a.side_bar_links:link {
color: #FFFFFF;
padding-left: 2px;
text-decoration: none;
}
a.side_bar_links:active {
color: #FFFFFF;
padding-left: 2px;
text-decoration: none;
}
a.side_bar_links:hover {
color: #FFFFFF;
padding-left: 2px;
text-decoration: none;
}
a.side_bar_links:visited {
color: #FFFFFF;
padding-left: 2px;
text-decoration: none;
}
a.main_menu_links:visited {
font-family: Verdana, Arial, Helvetica, sans-serif;
font-size: 10pt;
color: #FFFFFF;
text-decoration: none;
}
.side_bar_links_2 {
font-family: Arial, Helvetica, sans-serif;
font-size: 11pt;
font-weight: normal;
color: #000000;
text-decoration: none;
padding-left: 4px;
}
a.side_bar_links_2:link {
font-family: Arial, Helvetica, sans-serif;
font-size: 11pt;
font-weight: normal;
color: #000000;
text-decoration: none;
left: 2px;
padding-left: 5px;
}
a.side_bar_links_2:visited {
font-family: Arial, Helvetica, sans-serif;
font-size: 11pt;
font-weight: normal;
color: #000000;
text-decoration: none;
left: 2px;
padding-left: 5px;
}
a.side_bar_links_2:active {
font-family: Arial, Helvetica, sans-serif;
font-size: 11pt;
font-weight: normal;
color: #000000;
text-decoration: none;
left: 2px;
padding-left: 5px;
}
a.side_bar_links_2:hover {
font-family: Arial, Helvetica, sans-serif;
font-size: 11pt;
font-weight: normal;
color: #0052CC;
text-decoration: none;
left: 2px;
padding-left: 5px;
}
.main_menu_2 {
font-family: Verdana, Arial, Helvetica, sans-serif;
font-size: 10pt;
color: #68ADDF;
text-decoration: none;
}
a.main_menu_2:link {
font-family: Verdana, Arial, Helvetica, sans-serif;
font-size: 10pt;
color: #68ADDF;
text-decoration: none;
}
a.main_menu_2:hover {
font-family: Verdana, Arial, Helvetica, sans-serif;
font-size: 10pt;
color: #68ADDF;
text-decoration: none;
}
a.main_menu_2:active {
font-family: Verdana, Arial, Helvetica, sans-serif;
font-size: 10pt;
color: #68ADDF;
text-decoration: none;
}
a.main_menu_2:visited {
font-family: Verdana, Arial, Helvetica, sans-serif;
font-size: 10pt;
color: #68ADDF;
text-decoration: none;
}
.style27 {
font-size: 11pt;
color: #000000;
text-decoration: none;
padding-left: 4px;
font-family: Arial, Helvetica, sans-serif;
font-weight: bold;
}
.style1 {
font-family: Verdana, Arial, Helvetica, sans-serif;
font-weight: bold;
font-size: 12px;
color: #000000;
}
#search {
position: absolute;
top: auto;
right: 0px;
visibility: visible;
z-index: 3;
}
.style31 { font-family: Verdana, Arial, Helvetica, sans-serif;
font-weight: bold;
font-size: 12px;
}
.body_text_small {
font-family: Verdana, Arial, Helvetica, sans-serif;
font-size: 9pt;
font-style: normal;
color: #002967;
font-weight: normal;
border-top-width: 0px;
border-top-style: none;
border-top-color: #FFFFFF;
padding-top: 0px;
padding-right: 0px;
padding-bottom: 0px;
padding-left: 0px;
}
-->
</style>
</head>

  Mysticnas 08:55 29 Nov 05

<script language="JavaScript" type="text/JavaScript">
<!--
function MM_reloadPage(init) { //reloads the window if Nav4 resized
if (init==true) with (navigator) {if ((appName=="Netscape")&&(parseInt(appVersion)==4)) {
document.MM_pgW=innerWidth; document.MM_pgH=innerHeight; onresize=MM_reloadPage; }}
else if (innerWidth!=document.MM_pgW || innerHeight!=document.MM_pgH) location.reload();
}
MM_reloadPage(true);

<script language="JavaScript" type="text/JavaScript">
function MM_findObj(n, d) { //v4.01
var p,i,x; if(!d) d=document; if((p=n.indexOf("?"))>0&&parent.frames.length) {
d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);}
if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i<d.forms.length;i++) x=d.forms[i][n];
for(i=0;!x&&d.layers&&i<d.layers.length;i++) x=MM_findObj(n,d.layers[i].document);
if(!x && d.getElementById) x=d.getElementById(n); return x;
}

function MM_showHideLayers() { //v6.0
var i,p,v,obj,args=MM_showHideLayers.arguments;
for (i=0; i<(args.length-2); i+=3) if ((obj=MM_findObj(args[i]))!=null) { v=args[i+2];
if (obj.style) { obj=obj.style; v=(v=='show')?'visible':(v=='hide')?'hidden':v; }
obj.visibility=v; }
}

//-->
</script>
<style type="text/css">
<!--
.style7 {
font-size: 1px;
border-bottom-color: #E1F5FF;
border-color: #FFFFFF;
border-bottom-style: solid;
border-bottom-width: 1px;
}
.style8 {
font-family: Arial, Helvetica, sans-serif;
font-size: 10px;
color: #005FA9;
}
.style11 {font-size: 24px; color: #FFFFFF; }
body,td,th {
font-family: Verdana, Arial, Helvetica, sans-serif;
font-size: 10pt;
color: #FFFFFF;
border-top: 0;
border-top-color: #E1F5FF;
border-top-width: 0px;
border-color: #FFFFFF;
border-bottom-color: #E1F5FF;
border-bottom-style: solid;
border-bottom-width: 0px;
border-top-style: solid;
}
a:link {
color: #0052CC;
text-decoration: underline;
}
a:visited {
color: #0052CC;
text-decoration: underline;
}
a:hover {
color: #0052CC;
text-decoration: underline;
}
a:active {
color: #0052CC;
text-decoration: underline;
}
.style17 {color: #68ADDF}
.div_tag_1 {
border-top-width: 0px;
border-right-width: 0px;
border-bottom-width: 2px;
border-left-width: 0px;
border-top-color: #68ADDF;
border-right-color: #FFFFFF;
border-bottom-color: #E1F5FF;
border-left-color: #FFFFFF;
border-bottom-style: solid;
border-top-style: none;
font-size: 1px;
}
.header_text {
font-family: Arial, Helvetica, sans-serif;
font-size: 30pt;
font-weight: normal;
color: #FFFFFF;
background-image: none;
background-repeat: no-repeat;
background-position: left top;
background-attachment: fixed;
height: 85px;
vertical-align: baseline;
width: 565px;
font-style: normal;
line-height: normal;
text-align: left;
text-indent: 10px;
}
.style24 {font-size: 18px}
.side_bar {
font-family: Arial, Helvetica, sans-serif;
font-size: 11pt;
font-weight: normal;
color: #002967;
padding-left: 2px;
}
.a_link_2 {
color: #002967;
text-decoration: none;
font-size: 11px;
}
a:link {
color: #0052CC;
}
.main_menu_links {
color: #FFFFFF;
text-decoration: none;
}
a.main_menu_links:link {
font-family: Verdana, Arial, Helvetica, sans-serif;
font-size: 10pt;
color: #FFFFFF;
text-decoration: none;
}
a.main_menu_links:active {
font-family: Verdana, Arial, Helvetica, sans-serif;
font-size: 10pt;
color: #FFFFFF;
text-decoration: none;
}
a.main_menu_links:hover {
font-family: Verdana, Arial, Helvetica, sans-serif;
font-size: 10pt;
color: #FFFFFF;
text-decoration: none;
}

  Mysticnas 08:55 29 Nov 05

.side_bar_links {
font-family: Arial, Helvetica, sans-serif;
font-size: 11pt;
color: #FFFFFF;
text-decoration: none;
padding-left: 2px;
border-top: none;
border-right: none;
border-bottom: none;
border-left: none;
font-weight: bold;
}
a.side_bar_links:link {
color: #FFFFFF;
padding-left: 2px;
text-decoration: none;
}
a.side_bar_links:active {
color: #FFFFFF;
padding-left: 2px;
text-decoration: none;
}
a.side_bar_links:hover {
color: #FFFFFF;
padding-left: 2px;
text-decoration: none;
}
a.side_bar_links:visited {
color: #FFFFFF;
padding-left: 2px;
text-decoration: none;
}
a.main_menu_links:visited {
font-family: Verdana, Arial, Helvetica, sans-serif;
font-size: 10pt;
color: #FFFFFF;
text-decoration: none;
}
.side_bar_links_2 {
font-family: Arial, Helvetica, sans-serif;
font-size: 11pt;
font-weight: normal;
color: #000000;
text-decoration: none;
padding-left: 4px;
}
a.side_bar_links_2:link {
font-family: Arial, Helvetica, sans-serif;
font-size: 11pt;
font-weight: normal;
color: #000000;
text-decoration: none;
left: 2px;
padding-left: 5px;
}
a.side_bar_links_2:visited {
font-family: Arial, Helvetica, sans-serif;
font-size: 11pt;
font-weight: normal;
color: #000000;
text-decoration: none;
left: 2px;
padding-left: 5px;
}
a.side_bar_links_2:active {
font-family: Arial, Helvetica, sans-serif;
font-size: 11pt;
font-weight: normal;
color: #000000;
text-decoration: none;
left: 2px;
padding-left: 5px;
}
a.side_bar_links_2:hover {
font-family: Arial, Helvetica, sans-serif;
font-size: 11pt;
font-weight: normal;
color: #0052CC;
text-decoration: none;
left: 2px;
padding-left: 5px;
}
.main_menu_2 {
font-family: Verdana, Arial, Helvetica, sans-serif;
font-size: 10pt;
color: #68ADDF;
text-decoration: none;
}
a.main_menu_2:link {
font-family: Verdana, Arial, Helvetica, sans-serif;
font-size: 10pt;
color: #68ADDF;
text-decoration: none;
}
a.main_menu_2:hover {
font-family: Verdana, Arial, Helvetica, sans-serif;
font-size: 10pt;
color: #68ADDF;
text-decoration: none;
}
a.main_menu_2:active {
font-family: Verdana, Arial, Helvetica, sans-serif;
font-size: 10pt;
color: #68ADDF;
text-decoration: none;
}
a.main_menu_2:visited {
font-family: Verdana, Arial, Helvetica, sans-serif;
font-size: 10pt;
color: #68ADDF;
text-decoration: none;
}
.style27 {
font-size: 11pt;
color: #000000;
text-decoration: none;
padding-left: 4px;
font-family: Arial, Helvetica, sans-serif;
font-weight: bold;
}
.style1 {
font-family: Verdana, Arial, Helvetica, sans-serif;
font-weight: bold;
font-size: 12px;
color: #000000;
}
#search {
position: absolute;
top: auto;
right: 0px;
visibility: visible;
z-index: 3;
}

  Mysticnas 08:56 29 Nov 05

.style31 { font-family: Verdana, Arial, Helvetica, sans-serif;
font-weight: bold;
font-size: 12px;
}
.body_text_small {
font-family: Verdana, Arial, Helvetica, sans-serif;
font-size: 9pt;
font-style: normal;
color: #002967;
font-weight: normal;
border-top-width: 0px;
border-top-style: none;
border-top-color: #FFFFFF;
padding-top: 0px;
padding-right: 0px;
padding-bottom: 0px;
padding-left: 0px;
}
-->
</style>
</head>

<body>
<table width="100%" height="20" border="0" cellpadding="0" cellspacing="0">
<!--DWLayoutTable-->
<tr>
<td height="85" colspan="4" valign="top" nowrap><div id="search">
<table width="204" height="64" align="right">
<tbody>
<tr>
<td width="19" height="13" valign="middle" nowrap><span class="style1"><br>
<br>
<br>
</span></td>
<td width="173" height="28" rowspan="2" valign="middle" nowrap><table>
<tbody>
<tr>
<td valign="top"><form name=BnrSearch action=click here>
<input
type=hidden value=SearchResult name=space>
<input type=hidden
value=bannerstart name=in_hi_control>
<input type=hidden value=thisfold
name=in_se_sel_1>
<input name=in_tx_query size="24">
<select
name=in_hi_opt_thisfold_ddfolder>
<option value="53886" selected>Entire Site</option>
<option value=53888>Documents</option>
<option value="53887">Web Pages</option>
</select>
<input name=Submit1 type=image
value=Go src="images/search_button.gif" alt=search width="64" height="25">
</form></td>
</tr>
</tbody>
</table></td>
</tr>
<tr>
<td height="13" valign="middle" nowrap> </td>
</tr>
</tbody>
</table>
</div>
<div id="Layer2" style="position:absolute; width:565px; height:79px; z-index:1; left: 11px; top: 16px;"><img src="images/new%20banners/banner3.jpg" width="561" height="77"></div>
<div align="right"> </div></td>
</tr>
<tr bgcolor="#68ADDF">

This thread is now locked and can not be replied to.

How to get Windows 10 for free | How to install Windows 10: There is still a way to avoid paying…

1995-2015: How technology has changed the world in 20 years

Hands-on with the Star Wars fighting drones you can fly yourself

15 macOS Sierra tips | How to use macOS Sierra: Secret tricks and best new features in Apple's new…