jQuery error $('...').tooltip is not a function [Orlando-patch3]
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎05-21-2020 04:35 AM
Hi all,
After the upgrade to Orlando, a calendar widget with embedded modals just lost functionality. The Date/time fields wich were auto-populated now cannot be filled anymore. The browser console shows a log message with the following text:
jQuery.Deferred exception: $(...).tooltip is not a function TypeError: $(...).tooltip is not a function
at HTMLDocument.<anonymous>
I've searched and re-arranging the dependencies didn't worked for me. This is the depencencies we are using for the widget.
The CSS is only a fullcalendar css dependency. I've tried also including bootstrap and popper, and I think the error is becouse somewhere in the code, ServiceNow includes
$(document).ready(function() {
$('body').tooltip({
selector: '[data-toggle="tooltip"]'
});
});
Any suggestions to keep using jQuery without remodeling all the code of the widget? We need jQuery to access dates with moment and other look&feel changes that are much more difficult using DOM.
Thank you.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎05-21-2020 05:09 AM
Have you googled the error? Using tooltip requires the use of the title attribute and they may have removed it so you may need to find a way to put it back.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎05-21-2020 10:50 AM
Yes, I've searched a lot but I didn't find the way to solve it. What do you mean with the 'title' attribute? I don't know what is it.
Thanks

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎05-21-2020 11:08 AM
First one on the list
https://www.google.com/search?client=firefox-b-1-d&ei=3pXGXrDnBZnStQbVwImgBg&q=jquery+tooltip+not+a+function&oq=jquery+tooltip+not+a+fun&gs_lcp=CgZwc3ktYWIQAxgAMgIIADIGCAAQFhAeMgYIABAWEB4yBggAEBYQHjIGCAAQFhAeMgYIABAWEB4yBggAEBYQHjIGCAAQFhAeMgYIABAWEB4yBggAEBYQHjoECAAQRzoECAAQQzoFCAAQgwE6BggAEAoQQzoFCAAQkQJQxcy8BVjkoL0FYOmyvQVoAHABeACAAVqIAbwOkgECMjSYAQCgAQGqAQdnd3Mtd2l6&sclient=psy-ab
Indicates that you need the title attribute on the tag for the tooltip method to work.
<td title="This is a tooltip."></td>
Its possible that ServiceNow changed something.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎05-22-2020 01:19 AM
Yes but I don't have access to the body which is the element that throws the error. In the code that I shared the tooltip function is over the 'body' element of the HTML, but is internally created by ServiceNow, I mean I don't use .tooltip anywhere in my code, and even I don't have access to the HTML body tag directly, so I can't include the 'title' attribute, right?