On Mar 14, 2007, at 11:07 AM, Juha Suni wrote:

Daniel Hofstetter wrote:
Somehow I can't figure out how to bind a hover event to an element.

Something wrong with?
$(this).hover(
    functionA,functionB
);

Daniel,
Just to connect the dots for you, you'll often want to use anonymous functions for both arguments. So, it would look like this:

$(this).hover(function() {
  // Stuff to do when the mouse enters the element;
}, function() {
  // Stuff to do when the mouse leaves the element;
});

Don't know if you needed that extra explanation, but I guess it can't hurt. :)

--Karl
_________________
Karl Swedberg
www.englishrules.com
www.learningjquery.com


_______________________________________________
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/

Reply via email to