Hi
Well the simplest way would be to pass the element you want
to affect
<a href="bla" onmouseover="someFunction(theDivID)">bla</a>
--
Best Regards
Vidar Petursson
==============================
Microsoft Internet, Client, SDK MVP
==============================
http://www.icysoft.com
http://www.dna.is
==============================
No matter where you go there you are
-
Quote:
> Thanks,
> However in Netscape I am told that the parentElement does not exist. Is
this
> due to the different object layout in Netscape, and if so does anyone know
> how to access the parent Element in Netscape.
> > Hi
> > Really simple example :)
> > <div id="Daddy">
> > <a href="#" onmouseover="alert(this.parentElement.id)">bla</a>
> > </div>
> > Here is more info:
> > http://msdn.microsoft.com/workshop/
> > --
> > Best Regards
> > Vidar Petursson
> > ==============================
> > Microsoft Internet, Client, SDK MVP
> > ==============================
> > http://www.icysoft.com
> > http://www.dna.is
> > ==============================
> > No matter where you go there you are
> > > Hi,
> > > I'm having a problem making my page cross-brower compatible. The
> problem
> > > occurs where I try to use scripting. Before i used DIV tags and in IE
> > these
> > > allowed scripting, but not so in Netscape. So instead I decided to
use
> <a
> > > href=.....> inside my div tags.
> > > So I have:
> > > <DIV ID="TestLayer" STYLE="position:absolute;
> > > left:30px; top:200; width:230; height:120; background-color:#C0C0C0;
> > > layer-background-color:#C0C0C0;visibility:visible;}">
> > > <a name="blah" href="javascript:mouseclick(this)" onMouseOver="
> > > mouseon(this);"
> > > onMouseOut="mouseout(this)" text="the actual text">
> > > some text
> > > </a>
> > > </DIV>
> > > This is now almost working.
> > > The problem is now that where before I would pass my object events to
> the
> > > JS functions with
> > > onmouseclick=Click(this); but now this isn't an object. (Note that by
> > > setting the name attribute it actually causes the object to behave
> > > differently) Is there any way of referencing the containing div
tag(ie
> > > TestLayer)?
> > > Also the < a> tag is supposed to have a text property. However it
> doesn't
> > > seem to display this. Does anyone know of any way to display this?
> > > Thanks,
> > > Stephen