JavaScript implements the simple Tip box effect, and javascript implements the tip
This example describes how to implement a simple Tip box in JavaScript. We will share this with you for your reference. The details are as follows:
// JavaScript Documentdocument.write("<div id='tip' style='position:absolute; width:300px; z-index:1; background-color: #ffffff; border: 1px solid gray; overflow: visible;visibility: hidden;font-size:12px;padding:12px;color:#333333'></div>")function showtip(w){ var x=event.x; var y=event.y; tip.innerHTML=w; tip.style.visibility="visible"; tip.style.left=x+10; tip.style.pixelTop=y+document.body.scrollTop+10;}function hidetip(){ tip.style.innerHTML="" tip.style.visibility="hidden";}
Save as: showtip. js
<Table width = "100%" border = "0" cellspacing = "0" cellpadding = "0" background = "# F7F7F0"> <tr height = "25"> <td background = "images/line-dot.gif" height = "20" align = "left"> <a onmousemove = "showtip ('<B> title: </B> <br> graduate girls are more confident in packaging <br> ') "onmouseout = hidetip () href = 'common/NewsDetails. aspx? Id = 1035 'target = _ blank> graduate girls are more confident in packaging </a> </td> </tr> <td background = "images/point_h.gif" height = "1"> </td> </tr> </table>