custom tooltip value not removed on mouseleave

Sep 3, 2013 at 11:27 AM
I'm trying to create hover and on click stage to show tooltip values. facing difficulty to remove the tooltip value on mouseleave. value remains display on mouseleave.

var tooltipvalues = ['Bad', 'Poor', 'Average', 'Good', 'Excellent'];
$("#rateitHover").bind('over', function (event, value) {
$(".tooltip").text(tooltipvalues[value - 1]);
});
$("#rateitHover").bind('rated', function (event, value) {
$('.tooltip').text('Rated: ' + tooltipvalues[value - 1]);
});
Coordinator
Sep 9, 2013 at 8:01 AM
Just add:
$(".rateit").bind('mouseleave', function() {$('#hover5').empty();});