I have a deferred function that binds a mouseenter event:
$(window).load(function(e) {
var $container = $(\'.container\');
$container.mouseenter(function
With jQuery 1.7+ you're going to want to use .on(): http://api.jquery.com/on/
$(document).ready(function(){
$('body').on("mouseover", "your_element_selector_here", function() {
// do stuff here
});
});
.live is deprecated. You could also put any other events in .on as well, depending on what you need. :hover doesn't work because it only works with specific elements and it's css based.
Using this in conjunction with an offset detection approach for before the page finishes loading will get you where you want to be.