Skip to content

Instantly share code, notes, and snippets.

@rayners
Created July 8, 2010 00:51
Show Gist options
  • Save rayners/467503 to your computer and use it in GitHub Desktop.
Save rayners/467503 to your computer and use it in GitHub Desktop.
<html>
<head>
<script src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js"></script>
<script type="text/javascript">
function iity() {
var d = new Date();
var c_hour = d.getHours();
var value = 'Nope';
if (c_hour <= 1) {
value = 'YES!';
}
$('#iity').html('<p>' + value + '</p>');
}
$(document).ready(function() {
iity();
setInterval(iity, 2000);
});
</script>
</head>
<body>
<div id="iity"></div>
</body>
</html>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment