Skip to content
Related Articles
Open in App
Not now

Related Articles

jQuery UI Tooltips content Option

Improve Article
Save Article
Like Article
  • Last Updated : 19 Feb, 2021
Improve Article
Save Article
Like Article

jQuery UI consists of GUI widgets, visual effects, and themes implemented using jQuery, CSS, and HTML. jQuery UI is great for building UI interfaces for the webpages. jQuery UI tooltip widget helps us to add new themes and allows for customization. In this article, we will see how to use content option in tooltip.
content option is used to add some content in the tooltip.


$( ".selector" ).tooltips(
   { content: "GeeksforGeeks!" }


  • string: The value you want to insert in the tooltip.

Approach: First, add jQuery UI scripts needed for your project.

<link href=”” rel=”stylesheet”>
<script src=””></script>
<script src=””></script>

Example: The following example demonstrates the content option for the tooltip.


<!doctype html>
<html lang="en">
    <meta charset="utf-8">
    <link href=
    <h1 style="color:green;">
        jQuery UI | Tooltip content option
        $(function () {
                content: "GeeksforGeeks!"
    <label for="name">Name:</label>
    <input id="gfg1" title="GeeksforGeeks">
    <p><a id="gfg2" href="" title="GeeksforGeeks">
        Click here!



My Personal Notes arrow_drop_up
Like Article
Save Article
Related Articles

Start Your Coding Journey Now!