More FF issues with growing/shrinking divs

JavaScript and client side scripting.

Moderator: General Moderators

Post Reply
User avatar
Burrito
Spockulator
Posts: 4715
Joined: Wed Feb 04, 2004 8:15 pm
Location: Eden, Utah

More FF issues with growing/shrinking divs

Post by Burrito »

Ok, I got the growing portion of my divs worked out (figuring out the event location (x,y)), but now my divs are shrinking even when I'm not actually mousing out of them, see my code below for my div creations:

Code: Select all

echo &quote;<div id=\&quote;&quote;.$p.&quote;\&quote; class=\&quote;mag\&quote; onMouseOut=\&quote;demagDay('&quote;.$p.&quote;','frdiv')\&quote;><span id=\&quote;dacon&quote;.$p.&quote;\&quote; class=\&quote;size1\&quote;>&quote;.$stuff.&quote;</span></div>&quote;;
my demagDay function looks like this:

Code: Select all

function demagDay(where,evt){
	if(ie){
		var theDiv = event.srcElement;
		var t = event.toElement;
		while (t){
			t = t.parentNode;
			if (t == theDiv)
				return;
			}
	
		if(event.toElement.id != where){
			(evt ? shrinkIt(where,evt) : shrinkIt(where));
		}	
	}else{
		shrinkIt(where,evt);
	}
}
that function shouldn't be called unless I "mouseout" of the div element, yet it is even when I move my mouse at all...I could see it shrinking if I mouse over a hyperlink or something, but not just moving the mouse on the div????

any ideas?
User avatar
feyd
Neighborhood Spidermoddy
Posts: 31559
Joined: Mon Mar 29, 2004 3:24 pm
Location: Bothell, Washington, USA

Post by feyd »

Moved to Client-side. :?
Post Reply