Change Tooltip on mouseclick
Hi,
I want to change the text of my tooltip on mouseclick.
I got a button and over this button is a tooltip. Actually "open slider" - After I clicked that button there should be "close slider".
My Code:
- <!-- Toggle -->
<script>
$(document).ready(function(){
$("div.changereport").hide();
$("div.trigger").click(function(){
$("div.changereport").slideToggle("slow");
return false;
});
});
</script>
<!-- Toggle -->
<!-- ImageSwitch -->
<script>
$(function() {
var $images = $("#d1 > .c1 > a").clone();
var $length = $images.length;
var $imgShow = 0;
$("#d1 > .c1").html( $("#d1 > .c1 > a:first") );
$("#d1 > .c1 > a").click(function(event) {
$(this).children().attr("src",
$("img", $images).eq(++$imgShow % $length).attr("src") );
event.preventDefault();
});
});
</script>
<!-- ImageSwitch -->
<div class="trigger">
<div id="d1">
<div class="c1">
<a href="#" title="open slider" alt="open slider"><img src='<% image as="url" iEditPath="/layout/img/pic2.jpg" %>' id="button"></a>
<a href="#" title="close slider" alt="close slider"><img src='<% image as="url" iEditPath="/layout/img/pic1.jpg" %>' id="button"></a>
</div>
</div>
<div id="d"></div>
</div>