Move jQuery UI Tooltip with mouse

In my previous post, I had explained how to "create Tooltip using jQuery UI library". By Default, the tooltip appears next to the element and it doesn't move. Today, I will show you how can you make jQuery UI Tooltip follow the mouse. In short, the tooltip will move with the mouse.

jQuery UI Tooltip widget has a property called "track", which is when set to true then tooltip follows the mouse. By default it is false.

Below jQuery code, will set this property to true which makes tooltip to follow the mouse.
$(function() {
    $(document).tooltip({
        track:true
    });
});​
See result below


See Complete Code
Feel free to contact me for any help related to jQuery, I will gladly help you.
SHARE

Nothing shocks me, I'm a Software Engineer. And I am not young enough to know everything. I live in World Wide Web and from there take care of this website. This website communicates about my work, learning and experience. I believe life is short, and it is for loving, sharing, learning and connecting. So lets connect..