opentip使用引入opentip.css,jquery.js opentip-jquery.min.jscss
//頁面body 1<br> 1<br> 1<br> 1<br> 1<br> 1<br> <div id="showClick" style="background:red;">Click me</div> //默認顯示 <script> $(function(){ var myOpentip = new Opentip("#showClick"); myOpentip.setContent("tip-sss"); myOpentip.show(); }); </script> //------打開頁面後,提示直接顯示在左上角 //添加target及tipJoint修改後正常顯示 <script> $(function(){ $("#showClick").opentip("tip-sss",{style:'glass',target: "#showClick",tipJoint: "bottom"}).show(); }); </script>