tooltip on Confluence page

Hi, Can I include tooltips in my Confluence page, which would pop-up when I mouse -hover the text ? pls provide any detail that would be useful for me - on this front.

 

Thanks.

Jyothi

3 answers

This widget could not be displayed.
Davin Studer Community Champion Sep 15, 2015

Here is a user macro I created a while ago for this.

Macro Body Processing:
Rendered

Template: 

## Developed by: Davin Studer
## Date created: 04/30/2014
 
## @param Tip:title=Tool Tip|type=string|required=true|desc=What will be displayed when the cursor hovers over this area?
 
#set( $id = $action.dateFormatter.calendar.timeInMillis )
#set( $d = '$' )
#set( $p = '#' )
#requireResource("com.atlassian.auiplugin:aui-experimental-tooltips")
 
<span id="content$id" title="$paramTip">$body</span>
<script type="text/javascript">
AJS.toInit(function(){
    AJS.${d}("${p}content$id").tooltip({gravity: 's'});
});
</script>
This widget could not be displayed.

As administrator can add a user macro - see Charles Halls comment in this question: https://confluence.atlassian.com/display/DISC/Add+Tool+Tip+to+Normal+Text

## Macro title: My Macro
## Macro has a body: Y
## Body processing: Rendered
## Written by: Charles Hall
## Date installed: 
## Installed by: 

## @param tip:title=Tooltip text|type=string|required=true|default=Tooltip text|desc=Enter the text you want to appear as the tooltip
## @param bordercolour:title=Underline Colour|type=string|required=false|default=#336699|desc=Enter the hexadecimal colour code for the bottom border colour used for the dotted underline.
 
## Set default values
#if (!$paramtip)
  #set ($paramtip="Add Tooltip text here")
#end
#if (!$parambordercolour)
  #set ($parambordercolour="#336699")
#end
 
#set($tip=$paramtip)
#set($color=$parambordercolour)
 
<a style="text-decoration:none; border-bottom:1px dotted; border-bottom-color:$color" title="$tip">$body</a>
This widget could not be displayed.

Hi Jyothi,

Another options is the free Tooltips add-on. It allows adding tooltips over any content without needing to use macros. Hope that helps!

-Mike

Suggest an answer

Log in or Sign up to answer
Community showcase
Posted Monday in Confluence

Why start from scratch? Introducing four new templates for Confluence Cloud

Hi my Community friends!  For those who don't know me, I'm a product marketer on the Confluence Cloud team - nice to meet you! For those of you who do, you know that I've been all up in your Co...

409 views 4 6
Join discussion

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you