鼠标经过li列表 后 将li的字体加粗  并弹出一个div谢谢

解决方案 »

  1.   

    <body>
    <li onmouseover="this.style.fontWeight='bold';a=document.createElement('div');document.body.appendChild(a);a.style.border='1px solid red';with(a.style){position='absolute';top=100;left=100;width=100;height=100}" onmouseout="this.style.fontWeight='normal';document.body.removeChild(a)">ddd
    </li>
    </body>贴入代码直接运行,搞定
      

  2.   


    <li onmouseover="this.style.fontWeight='bold';a=document.createElement('div');document.body.appendChild(a);a.style.border='1px solid red';with(a.style){position='absolute';top=this.style.top;left=this.style.left+50;width=100;height=100}" onmouseout="this.style.fontWeight='normal';document.body.removeChild(a)">ddd 
    </li>