TooltipExample 自定義鼠标提示

    
        Style Example
         function showTip(oEvent) {
                var oDiv = document.getElementById(“divTip1”);
                oDiv.style.visibility = “visible”;
                oDiv.style.left = oEvent.clientX + 5;
                oDiv.style.top = oEvent.clientY + 5;
            }
 
            function hideTip(oEvent) {
                var oDiv = document.getElementById(“divTip1”);
                oDiv.style.visibility = “hidden”;
            }                            

Move your mouse over the red square.

         style=”background-color: red; height: 50px; width: 50px”
             onmouseover=”showTip(event)” onmouseout=”hideTip(event)”>
 
          style=”background-color: yellow; position: absolute; visibility: hidden; padding: 5px”>
            Custom Tooltip More details can go here.               

Copyright © Bruce Huang All rights reserved.