Sunday, July 15, 2012

How To Add jQuery Tooltip To Blogger Blog

Author: Gagan Masoun
How To Add jQuery Tooltip To Blogger Blog
Build a Better Tooltip with jQuery AwesomenessA tooltip is a box that appears when you hover your cursor over the text like a hyperlink. It provides supplementary information about that text with useful description. This simple tutorial will guide you "How To Add jQuery Tooltip To Blogger Blog".

I am re-sharing this from Help Blogger Blog. To see a tooltip in action, visit the link given below. Let's start working on this tutorial.

Live jQuery Tooltip Demo Below


How To Add jQuery Tooltip To Blogger Blog

1. Adding Tooltip Scripts

  • Go to Blogger Dashboard > Template
  • Take Back Of Your Template Before Make Any Change
  • Click On Edit HTML
  • Click On Proceed Button
  • Find Below Code In Your Template
</head>

  • Add Below Code Just Above/Before It
<script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.7.1/jquery.min.js"></script>
<script type="text/javascript" src="http://code.helperblogger.com/jquery-tooltip.js"></script>
Note - If you have already added a jQuery plugin to your blog then don't add the first line from above code.

2. Adding Tooltip Styles

  • Find Below Code In Your Template
]]></b:skin>

  • Add Below Code Just Above It
.tip {
width: 212px;
padding-top: 37px;
overflow: hidden;
display: none;
position: absolute;
z-index: 500;
background: transparent url(https://lh6.googleusercontent.com/-0KM2ludeMBo/UALZZEBrqBI/AAAAAAAACmc/s-SnyEbuwR8/s1600/hb_tipTop.png) no-repeat top;
}
.tipMid {
background: transparent url(https://lh4.googleusercontent.com/-Vu0rxFVABjQ/UALZYWnIryI/AAAAAAAACmY/M6hXn5zozh4/s1600/hb_tipMid.png) repeat-y;
padding: 0 25px 20px 25px;
}
.tipBtm {
background: transparent url(https://lh3.googleusercontent.com/-fcuks1eGyhM/UALZXjVS6CI/AAAAAAAACmQ/GZF8z7d7S4c/s1600/hb_tipBtm.png) no-repeat bottom;
height: 32px;
}

3. Using The Tooltip 

If you want to add tooltip in blogger posts,then go to Edit HTML tab and add below code inside it.
<div class="tTip" title="Add Tooltip Message Here">Add Your Text Here</div>
  • Replace Add Tooltip Message Here with the message which you want to appear in tooltip.
  • Replace Add Your Text Here with the text on which you want to appear tooltip.
If you need any other help, you can ask via comments any time.

0 comments:

Post a Comment