摘要: <body onload="color()"></body> <script> function color(){ 方法一: document.getElementByTagName("body").style.background = '#'+Math.floor(Math.random()*25 阅读全文
posted @ 2017-11-02 17:12 MiniDuck 阅读(2211) 评论(1) 推荐(0) 编辑
摘要: <img src="images/music.png" id="music" class="rotate"> <audio src="images/music.mp3?v=982" autoplay="autoplay" loop id="muc"></audio> css /*音乐*/#music 阅读全文
posted @ 2017-11-02 15:59 MiniDuck 阅读(372) 评论(0) 推荐(0) 编辑
摘要: 我需要的效果: html: <img src="images/my1.jpg" width="20%"/> css: img{-webkit-box-reflect: below 0px -webkit-gradient(linear, left top, left bottom, from(tra 阅读全文
posted @ 2017-11-02 15:39 MiniDuck 阅读(1314) 评论(0) 推荐(0) 编辑
摘要: document.onkeydown = function(ev){ var e = ev || event; if(e.keyCode == 32){ return false; } } 阅读全文
posted @ 2017-11-02 14:25 MiniDuck 阅读(2508) 评论(1) 推荐(0) 编辑
摘要: 摘要 为了保护我们的代码,我们需要想些办法禁止复制。 css: body{ -webkit-touch-callout: none; -webkit-user-select: none; -khtml-user-select: none; -moz-user-select: none; -ms-us 阅读全文
posted @ 2017-11-02 11:35 MiniDuck 阅读(4721) 评论(0) 推荐(0) 编辑
摘要: 目前我也不明白 阅读全文
posted @ 2017-11-02 11:03 MiniDuck 阅读(136) 评论(0) 推荐(0) 编辑
摘要: Js函数的概念、作用、创建、调用 一.函数是用来帮助我们封装、调用代码的最方便的工具! 二.函数的创建方法有3种: 1):function fun(){ console.log(3); //return this; //为什么函数会输出函数体中的内容,因为在函数体的最后 //默认会有一个return 阅读全文
posted @ 2017-11-02 10:45 MiniDuck 阅读(217) 评论(0) 推荐(0) 编辑