this.ToolTip = function(){              

 

                /* CONFIG */

 

                                                                xOffset = -10;

 

                                                                yOffset = -10;

 

                                                                // these 2 variable determine popup's distance from the cursor

 

                                                                // you might want to adjust to get the right result

 

                                                                var dir=$('body').css('direction');

 

                                                                var xPos;

 

 

                /* END CONFIG */

 

                $(".ECal tr:gt(1) td a").hover(function(e){

 

                        xPos=((dir=='rtl')?(e.pageX-imageWidth+xOffset):(e.pageX + xOffset));

                                                                                                //subtract image width in arabic version to appear on the left side of the cursor

                                                                                                $('#Tooltip').html($(this).parent().find('div').html())

                                                                                                $('#Tooltip').css("top",(e.pageY + yOffset) + "px")

                                                                                                                                                 .css("left",(xPos) + "px")

                                                                                                                                                 .css("visibility","visible")

                                                                                                                                                 .css("display","block");

  },function(){});

    $('#Tooltip').hover(function(){$(this).show()},function(){$(this).hide();});


};


$(document).ready(function(){

                $('body').append('<div id="Tooltip" class="balloonstyle" style="display: none;"></div>');

                ToolTip();

                                                                

 

});

