I’m using tooltips from Twitter Bootstrap package to show items information on the page. Sometimes information is changed, and needs to be updated in the tooltip. I tried simply to reinitialize tooltip with new title:
$('#selector').tooltip({ title: 'new text'});
However tooltip’s title doesn’t get changed with the new text. It remains the same as it was set initially. Any ideas why, and is there any work around? Thanks!
You can’t override the tooltip object once you have initialized it on one element. But you can delete it and do it again.
Try deleting and then reinitialize the tooltip with all your options (if you had any).
There may be a need to remove the listeners, but it works like that.
Before TWBS v3 you would not need the
bsnamespace giving :data('tooltip')