你的位置:首页 > 软件开发 > 网页设计 > 2015.08.11

2015.08.11

发布时间:2015-08-11 13:00:15
简单的demo,点击切换背景颜色切换,附上代码。.html文件<div> class=red id="box">美美哒!...........</div>.css文件.red{ width:100px; height:10 ...

简单的demo,点击切换背景颜色切换,附上代码。

window.onload = function(){ var box = document.getElementById('box'); box.onclick = toYellow;};function toRed(){  this.className ='red';  this.onclick = toYellow;}function toYellow(){ this.className ='yellow'; this.onclick = toRed;}

原标题:2015.08.11

关键词:

*特别声明:以上内容来自于网络收集,著作权属原作者所有,如有侵权,请联系我们: admin#shaoqun.com (#换成@)。

可能感兴趣文章

我的浏览记录