|
-
Jan 15th, 2002, 02:31 PM
#1
Thread Starter
Frenzied Member
Netscape 6 problem
I am trying to get an image map to work for NS6 and it stops when it gets to this line:
Code:
eval("window.div" + varRegion + ".style.visibility = \"visible\"");
this line was written to be interpreted by IE and I'm not sure what NS 6 thinks of it but I placed alerts all through the code and this is the line that follows the last alert to show meaning that it is halting here.
thanks in advance,
Michael
I'm off to GalahTech, hope to see you there.
If you don't like the rules they make, refuse to play their game. -- Steve Ignorant.
-
Jan 15th, 2002, 03:05 PM
#2
Addicted Member
NS 6 uses a different Document Object Model (DOM) than IE. Sometimes your objects will work the same in both browsers, but often they won't.
It looks like you are probably working with div's ("div" + varRegion), however, div's don't work too well in NS 6. Div's have much more flexibility in IE than in NS. However Layers in NS 6 is the DIV analogue.
As I understand your problem, you are wanting some tiny pop-up "windows" to appear onMouseover with their own background colors. I think this should be achievable using layers.
HTH
cudabean
-
Jan 15th, 2002, 03:08 PM
#3
Frenzied Member
Code:
<html>
<head></head>
<body>
<p id="foo">Hello, world.</p>
<script type="text/javascript">
var myFoo = document.getElementById("foo");
myFoo.style.color = "blue";
</script>
</body>
</html>
That should be W3C HTML and CSS DOM and ECMA-262 compliant. It should not us any MS proprietary extensions to JavaScript. For more information:
http://www.w3c.org/
http://www.ecma.org/
http://developer.netscape.org/
Travis, Kung Foo Journeyman
As always, RTFM.
WWW Standards: HTML 4.01, CSS Level 2, ECMA 262 Bindings to DOM Level 1, JavaScript 1.3 Guide and Reference
Perl: Learn Perl, Llama, Camel, Cookbook, Perl Monks, Perl Mongers, O'Reilly's Perl.com, ActiveState, CPAN, TPJ, and use Perl;
YBMS, but Mozilla doesn't.
-
Jan 15th, 2002, 03:13 PM
#4
Frenzied Member
Cuda, layers has been dropped from JavaScript. Further more, there is not two seperate DOMs. There is the W3C DOM, the ECMA mapping, and JavaScript's support of the ECMA standard. What you see as the IE DOM is propreitary extensions to undermind the standard.
Travis, Kung Foo Journeyman
As always, RTFM.
WWW Standards: HTML 4.01, CSS Level 2, ECMA 262 Bindings to DOM Level 1, JavaScript 1.3 Guide and Reference
Perl: Learn Perl, Llama, Camel, Cookbook, Perl Monks, Perl Mongers, O'Reilly's Perl.com, ActiveState, CPAN, TPJ, and use Perl;
YBMS, but Mozilla doesn't.
-
Jan 15th, 2002, 03:51 PM
#5
Thread Starter
Frenzied Member
Originally posted by Cudabean
However Layers in NS 6 is the DIV analogue....I think this should be achievable using layers.
I was under the impression that NS6 dropped the use of layers and adopted Div's is this not correct?
I'm off to GalahTech, hope to see you there.
If you don't like the rules they make, refuse to play their game. -- Steve Ignorant.
-
Jan 15th, 2002, 04:07 PM
#6
Thread Starter
Frenzied Member
Cyberthug...
sorry for my ignorance but you lost me on that reply with the code snippit
these are 2 other posts that i have made that refer to what I am trying to do here:
http://www.vbforums.com/showthread.p...hreadid=133095
http://www.vbforums.com/showthread.p...hreadid=133095
I'm off to GalahTech, hope to see you there.
If you don't like the rules they make, refuse to play their game. -- Steve Ignorant.
-
Jan 18th, 2002, 12:28 PM
#7
Thread Starter
Frenzied Member
got it :)
Code:
eval("document.getElementById('div' + varRegion ).style.visibility = \"visible\"");
fixes the problem and works for ie 5+ 
Now I have to make the previus menus dissapear when the user clicks for a new one but I think i can handle that 
thanks to nitwit @ Website Abstraction Help Forum for the code,
and thanks to all who helped here,
Michael
I'm off to GalahTech, hope to see you there.
If you don't like the rules they make, refuse to play their game. -- Steve Ignorant.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|