Solved

any idea why my mouseout is not working?

Posted on 2011-02-18
3
354 Views
Last Modified: 2012-05-11
http://www.picnictime.com/productsTest.php?pid=9191&cid=52&page=1

On this page I have a function that is supposed to generate a jquery hover popup (the thumbnails under the Enlarge Image link).  I also have an onmouseout function that does not appear to be working.  Does anyone have any idea why?

Thanks!
0
Comment
Question by:JGoyer
3 Comments
 
LVL 40

Accepted Solution

by:
gurvinder372 earned 500 total points
ID: 34925299
add the following lines

$("a:has(img.productsImg)").mouseout(
            function() {
                $("#tooltip1").hide();
}
        );
0
 
LVL 11

Expert Comment

by:Ovid Burke
ID: 34925379
jQuery.hover takes two handlers: for the mouseover state, and then the mouse out state.

$("a:has(img.productsImg)").hover(
	function() {
		var largePath = $(this).attr("title");
		var offset = $("#hoverImgs").offset();
		
		$("#photo_large").attr({ src: largePath });
		$("#tooltip1").css("top", offset.top).css("left", offset.left).css("display", "block");
		$("#tooltip1").animate({ opacity: 1.0 }, 300);
	},
	function() {
		$("#tooltip1").animate({ opacity: 0.0 }, 300);
		$("#tooltip1").css("display", "none");
	}
);

Open in new window

0
 
LVL 2

Author Closing Comment

by:JGoyer
ID: 34926317
That is perfect.  Thanks!
0

Featured Post

Why You Should Analyze Threat Actor TTPs

After years of analyzing threat actor behavior, it’s become clear that at any given time there are specific tactics, techniques, and procedures (TTPs) that are particularly prevalent. By analyzing and understanding these TTPs, you can dramatically enhance your security program.

Join & Write a Comment

How to build a simple, quick and effective accordion menu using just 15 lines of jQuery and 2 css classes
Introduction JSON is an acronym for JavaScript Object Notation.  It is a text-string data transport mechanism, capable of representing simple or complex data structures in a consistent and easy-to-read manner.  Similar in concept to XML, but more e…
The viewer will learn how to dynamically set the form action using jQuery.
The viewer will learn the basics of jQuery including how to code hide show and toggles. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery…

707 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

12 Experts available now in Live!

Get 1:1 Help Now