If you open the following url in Internet Explorer (IE6/7/8) and hover over the "Find Portrait" link a popup shows up. When you try to select a value from the month or year dropdown, Internet Explorer loses focus and the popup closes. It shouldn't close. This happens only in Internet Explorer. jQuery v.1.3.2 is used for the events handling. Any suggestions about this problem? Thank you!
A:
on the mouseout handler, do not hide the box before checking a flag. set the flag when you mouse over the date picker, and unset it when you mouseout.
mkoryak
2009-07-16 15:14:05
+1
A:
Your problem is that you're using mouseover and mouseout functions. Try using hover() instead, that should consider nested elements for you.
The problem is that when you hover the SELECT
element, actually your "leaving" your bubble, and it's closed.
As I said, use hover() instead.
Seb
2009-07-16 15:15:54
@Seb, changing the mouseover() to hover() didn't work.
dalizard
2009-07-16 15:38:40
Could you please post your new code? You should use hover() with both the bubble and the links. Also, consider using a flag as mkoryak said: whenever you enter the nav and bubble, set a common variable to TRUE; when out, set it to FALSE. So, whenever you want to hide the bubble, check if that flag is set to TRUE or not; that'll tell you if the user's over one of the two things.
Seb
2009-07-16 18:17:32
@Sed, I tried it with a flag - worked fine. The problem actually comes from the event bubbling. When you "leave" the <select> element this triggers an event that "bubbles" through the parent elements. So simply adding stopPropagation() to the 'mouseout' function for the <select> element fixes the problem. Apparently, there are some other issues like the fact that this doesn't quote work all the time, but I will spend more time on it tomorrow. 'setTimeout' will probably be the key when fighting around with IE. Thank you Seb for the help though!
dalizard
2009-07-16 22:13:28