Netscape layer prob
Afternoon all,
I have a layer for a menu bar that is draggable - hence the menu can be placed anywhere. This menu bar obviously has links - mine are through an image map of five buttons.
In IE, these buttons are clickable and thus take me to whatever page, but in Netscape the buttons are clickable but they do nothing. Because the layer that holds this menu bar is draggable, Netscape, I assume, is thinking I'm clicking the buttons with a view to moving the layer and hence not registering a click.
I've tried separating the buttons onto a nested layer with a higher Z-index but to no avail.
Here's the code for the layer and menu bar (if it works) :
<div id="Layer1" style="position:absolute; width:155px; height:272px; z-index:20000; left: 40px; top: 50px">
<table cellspacing=0 cellpadding=0 border=0 width=155>
<tr>
<td colspan=3><img src="construct/1.gif" width=155 height=34></td>
</tr>
<tr>
<td><img src="construct/2.gif" width=10 height=11></td>
<td><img src="construct/3.gif" width=135 height=11></td>
<td><img src="construct/4.gif" width=10 height=11></td>
</tr>
<tr>
<td valign=top><img src="construct/5.gif" width=10 height=29></td>
<td valign=top>
<table cellspacing=0 cellpadding=3 border=0 width=135>
<tr>
<td height=150 background="construct/back.gif" class=menuwhite>Yeovil Festival of Transport 2000<br><br>Castle Combe 50th Anniversary<br><br>Thruxton 26th March (Powertour)<br><br>Castle Combe Anglo-American</td>
</tr>
</table>
</td>
<td> </td>
</tr>
<tr>
<td height=16></td>
<td><img src="construct/6.gif" width=135 height=16></td>
<td><img src="construct/7.gif" width=10 height=16></td>
</tr>
<tr>
<td> </td>
<td><img src="construct/8.gif" width=135 height=19></td>
<td><img src="construct/9.gif" width=10 height=19></td>
</tr>
<tr>
<td> </td>
<td><map name="menumap">
<area shape="circle" coords="114,6,7" href="design.html" alt="design" onkeydown="loadpage('design.html')">
<area shape="circle" coords="94,15,7" href="links.html" alt="links">
<area shape="circle" coords="68,19,7" href="tips.html" alt="tips">
<area shape="circle" coords="43,16,7" href="photos.html">
<area shape="circle" coords="24,7,7" href="home.html" alt="photos">
</map><img src="construct/10.gif" width=135 height=28 isMap usemap="#menumap" border=0 name="arse"></td>
<td><img src="construct/11.gif" width=10 height=28></td>
</tr>
</table>
</div>
Cheers for any help.
Toodle-oo
Graham
Vincent Puglia posted this at 16:55 — 12th October 2000.
They have: 634 posts
Joined: Dec 1999
Hi Graham1,
& welcome to the forum
Let me preface this with: I didn't test your code and I haven't had that much experience with image maps. However...
Netscape handles layers somewhat differently than IE. For one, each layer has a complete DOM (document object model) within itself. So, the usual method for accessing a NN layer would be:
document.layers.layerID.document......
Secondly, Netscape has definite problems with divs inside of tables.
Finally, you do know that the first few images are non-clickable because they have no href tags, right?
That said, it is my guess that NN doesn't know that the image map exists. You may need to set up appropriate event handlers. To be sure of what is going on, I would place the following code after the div's html:
<script language='javascript'>
</script>
The above will list all of the properties your Layer1 has.
Where the world once stood
the blades of grass cut me still
GrahamI posted this at 17:35 — 12th October 2000.
They have: 11 posts
Joined: Oct 2000
Thanks for the info BUT quite a bit of it is gobbledegook to me, I'm afraid. I'm just starting to experiment with DHTML by re-designing my site thus adding the menu bar thing as a floating tool.
I've used the draggable layer code from Dreamweaver 2 and that works perfectly in both IE and Netscape. I can drag it about all day. But, as you can imagine, a floating menu isn't any good if you can't click anything.
Other sites I've seen have a little tab that you use to drag a layer but I can't fathom the code. I've tried to latch the dragging code onto the top bit (1.gif) and it works, but the whole menu is still draggable on any part of it and the links still don't work. I've also tried enclosing Layer 1 within another layer (Layer 2) with the code latched onto 1.gif but all that happens is I drag the top bit about while the rest of the menu stays where it is.
I can post a browser screenshot if you like - maybe it would show what I'm doing a little better???
Want me to post the Dreamweaver code? It's very long.
Vincent Puglia posted this at 23:22 — 12th October 2000.
They have: 634 posts
Joined: Dec 1999
Hi Graham,
How about a url? So I can actually see it That way we don't take up that room.
Also, you might want to see the "dHTML: an Introduction" script/tutorial at my site.
Vinny
Where the world once stood
the blades of grass cut me still
GrahamI posted this at 13:45 — 14th October 2000.
They have: 11 posts
Joined: Oct 2000
I'll post up a URL later on.
GrahamI posted this at 18:21 — 14th October 2000.
They have: 11 posts
Joined: Oct 2000
Here's the URL - it's just one page.
http://www.british-motorsport.fsnet.co.uk
GrahamI posted this at 11:56 — 15th October 2000.
They have: 11 posts
Joined: Oct 2000
Hello?
Vincent Puglia posted this at 06:21 — 16th October 2000.
They have: 634 posts
Joined: Dec 1999
Hi Graham,
Just got it; I'll look it over in the morning and try to get back to you sometime tomorrow. Ok?
Vinny
GrahamI posted this at 11:32 — 16th October 2000.
They have: 11 posts
Joined: Oct 2000
Okee-dokey. Cheers.
Morning for you is, er, umm, afternoon for me... I think.
Want to join the discussion? Create an account or log in if you already have one. Joining is fast, free and painless! We’ll even whisk you back here when you’ve finished.