1

How can i set a tooltip for certain html element if I either know the class or id.

I have tried this so far but no luck.

$("[id*=lblAvgKPI]").tooltip();
nicael
  • 18,550
  • 13
  • 57
  • 90
user1263981
  • 2,953
  • 8
  • 57
  • 98

1 Answers1

1

To test for both id myId or class myClass you can add them both to your selector separated by a ,.

$("#myId, .myClass").tooltip();
Jan
  • 5,688
  • 3
  • 27
  • 44