Created
August 23, 2012 04:24
-
-
Save whyisjake/3432297 to your computer and use it in GitHub Desktop.
Trip Out
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
<html> | |
<head> | |
<title>Random Color</title> | |
<link href="http://twitter.github.com/bootstrap/assets/css/bootstrap.css" rel="stylesheet"> | |
<style type="text/css"> | |
body { | |
background-color:#<?php echo substr(md5(rand()), 0, 6); ?>; | |
overflow: hidden; | |
} | |
.span1 { | |
width: 20px; | |
border-radius: 20px; | |
} | |
</style> | |
<script> | |
function blink() { | |
setTimeout(function() { | |
window.location.reload() | |
}, 600) }; | |
</script> | |
</head> | |
<body onload="blink()"> | |
<div class="container"> | |
<?php | |
foreach (range(0, 50) as $number) { | |
echo '<div class="row">'; | |
foreach (range(0, 11) as $number) { | |
echo '<div class="span1" style="background-color:#'.substr(md5(rand()), 0, 6).'"> </div>'; | |
} | |
echo '</div>'; | |
} | |
?> | |
</div> | |
</body> | |
</html> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment