Re: IE8 - jscript - layers

Tech Tip: Click here to run a free scan for Windows Errors and optimize PC performance



Hotrod Harry wrote on 28 aug 2008 in microsoft.public.scripting.jscript:

With the comma, it would never work, not in IE8, nor in IE0.3.

Actually I'm using this

<area href="javascript:hideAll(),ShowContent('nab11')" shape="rect"
coords="199, 87, 264, 107" /> on this part.

instead of <a href="javascript:hideAll(), ShowContent('nab11')"></a>

The comma works fine. As mentioned earlier, it works fine in IE7 and
FF3. Thanks for you reply

Good for you.

I would not trust it to be crossbrowser compliant with a comma,
as it is not mainstream javascript,
meseems.

Even better, do not use href and javascript:, try:

<area NOHREF
onclick = "hideAll();ShowContent('nab11')"
shape = 'rect'
coords = '199, 87, 264, 107'
style = 'cursor:pointer;'


And if you need to do this for many area's:

onclick = "hideAllShowContent('nab11')"

function hideAllShowContent(x) {
hideAll()
..........


--
Evertjan.
The Netherlands.
(Please change the x'es to dots in my emailaddress)
.