JS realizes the random color jump of Jiugong

js实现九宫格的随机颜色跳转

Initial map

js实现九宫格的随机颜色跳转

2) Start flash

  Nine-pace   DIV {Width: 190px; Height: # ffa600; float: Left; margin: 10px; border-radius: 10px;} body {width: 700px; margin: 0 auto;} Button {CLEAR: BOTH Width: 200px; Height: 50px; Background: #fff; Border: None; Border-Radius: 10px; Position: Relative; Left: 100px;} Button: Hover {Background: # ffa600;}        
ends flash
var div = document.getlementsBytagname ('div "); var colors = [' red ',' plum", ' Blue ',' Green ',' Cyan ',' Black ',' Pink ',' Gray ',' Brown']; btnone.onclick = function () {// Click Start c = setInterval (function () {// Using Timer Start (); // Call Function}, 1000) // Setting Time} btntwo.onclick = function () {// stop button for for (i = 0; i
The above is all the contents of this article, it is desirable to the content I can bring some help to everyone's learning or work, and I hope to support Tumi Cloud!
© Copyright Notice
THE END
Just support it if you like
like0
share
comment Grab the couch

Please log in to comment