Created
January 18, 2013 14:29
-
-
Save pawelmhm/4564901 to your computer and use it in GitHub Desktop.
Revisions
-
pawelmhm revised this gist
Jan 19, 2013 . 1 changed file with 11 additions and 3 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -1,11 +1,19 @@ (function () { var diver = document.getElementById('classer'); var IntervalId; var oczy = ["niebieskie", "czarne", "zielone"]; IntervalId = setInterval(flashtext,200); function flashtext() { for (var i=0;i<oczy.length; i++) { message = i + ". "+ "Moje oczy sa " + oczy[i]; diver.innerHTML = message; } } //function flashtext() { //diver.style.background = diver.style.background == "purple" ? "red" : "purple"; //} })(); -
pawelmhm revised this gist
Jan 19, 2013 . 2 changed files with 6 additions and 11 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -2,8 +2,6 @@ * The first commented line is your dabblet’s title */ #classer { width:300px; height:300px; margin:auto; This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -1,14 +1,11 @@ (function () { var diver = document.getElementById('classer'); var IntervalId; IntervalId = setInterval(flashtext,200); function flashtext() { diver.style.background = diver.style.background == "purple" ? "red" : "purple"; } })(); -
pawelmhm revised this gist
Jan 19, 2013 . 1 changed file with 2 additions and 1 deletion.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -1,7 +1,8 @@ (function () { var diver = document.getElementById('classer'); var colorki = ['red','purple','powderblue','violet']; diver.onmouseout = run; function run() {diver.style.background = colorki[1];} function eleme () { -
pawelmhm revised this gist
Jan 18, 2013 . 1 changed file with 13 additions and 13 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -1,13 +1,13 @@ (function () { var diver = document.getElementById('classer'); var colorki = ['red','purple','powderblue','violet']; diver.onclick = eleme; function eleme () { for (var i=0;i<colorki.length;i++) { setInterval(function(){diver.style.background = colorki[i];},20); } } })(); -
pawelmhm created this gist
Jan 18, 2013 .There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,10 @@ /** * The first commented line is your dabblet’s title */ #classer { background: #f06; background: linear-gradient(45deg, #f06, yellow); width:300px; height:300px; margin:auto; } This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,5 @@ <!-- content to be placed inside <body>…</body> --> <div id="classer"> </div> This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,13 @@ var diver = document.getElementById('classer'); var colorki = ['red','purple','powderblue','violet']; diver.onmouseout = ini; //an exercise in arrays, each color will be displayed for 30 seconds; function ini () { for (i=0;i<colorki.length;i++) { function switcher () { diver.style.background = colorki[i];} setInterval(switcher, 30); } } This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1 @@ {"view":"split","fontsize":"100","seethrough":"","prefixfree":"1","page":"javascript"}