Ask questions and get good answers on jQuery

Hallo, the script at the moment works creating a tooltip everytime there is a title reference. Do you think could be possibile make work the script only for title inside a certain class link (for example “info”)? In which way? I have tried but unsuccesfully. Thanks a lot!

asked Apr 23 '10 at 14:39

Mark's gravatar image

Mark
111


Actually there's a bug while managing the live jquery event to init mb.tooltip on ajax loaded element that prevents to specify a a specific DOM element for the tooltip.

A Workaround is:

line 37:

if (this.options.live)$("[title]").live("mouseover",function(){$(this).mbTooltip(options);});

should be:

if (this.options.live)$(".tuaClasse[title]").live("mouseover",function(){$(this).mbTooltip(options);});

linea 38:

var ttEl=$(this).is("[title]")? $(this): $(this).find("[title]");

should be:

var ttEl=$(this).is(".tuaClasse[title]")? $(this): $(this).find(".tuaClasse[title]");

I hope to publish soon a bugfix.

answered Apr 23 '10 at 15:05

Matteo%20Bicocchi's gravatar image

Matteo Bicocchi ♦♦
1776129

Your answer
toggle preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Tags:

Asked: Apr 23 '10 at 14:39

Seen: 336 times

Last updated: Aug 13 '10 at 17:23

Related questions

jQuery main site - Matteo Bicocchi