摘要: 1、有一个表格,当鼠标移动到某行时,该行变红,移除时,变为白色 <body> <table border="1" width="300px"> <tr onmouseover="t1(0);" onmouseout="t2(0);"> <td>1</td> <td>2</td> <td>3</td> 阅读全文
posted @ 2020-03-29 18:36 凸凸yolotheway 阅读(149) 评论(0) 推荐(0) 编辑
摘要: 1、事件: 行为 样式 结构 相分离的页面 js css html 绑定事件的两种方式: (1)直接标签绑定,onclick='xxx()'; (2)先获取Dom对象,然后进行绑定 document.getElementById('xx').onclick document.getElementBy 阅读全文
posted @ 2020-03-29 17:25 凸凸yolotheway 阅读(120) 评论(0) 推荐(0) 编辑
摘要: 1、定时分为单次定时器跟多次定时器 (1)单次定时器 setTimeout 单次定时器; clearTimeout 清除单次定时器 var obj=setTimeout(function(){},1000) clearTimeout(obj); (2)多次定时器 setInterval 多次定时器 阅读全文
posted @ 2020-03-29 16:54 凸凸yolotheway 阅读(261) 评论(0) 推荐(0) 编辑