Created
April 11, 2016 01:58
-
-
Save lunacodes/45e2b29f4cd94e36c2dfba2ecc2210f5 to your computer and use it in GitHub Desktop.
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 characters
$(document).ready(function() { | |
var $children = $("#tag_cloud").children("a") | |
console.log($children) | |
var $color_list = ['red', 'blue', 'yellow', 'green'] | |
for (i = 1; i < $children.length - 1; i++) { | |
var $random_color = $color_list[Math.floor(Math.random()*$color_list.length)]; | |
$children[i].css("color", $random_color) | |
} | |
console.log(red); | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment