I Am Not Myself

Bills.Pay(Developer.Skills).ShouldBeTrue()

My April Fools Day Prank

Slipped this into my application sometime last week. Wonder when my users will notice.

$(document).keyup(function() {
    if(itIsAprilFoolsDay())
        $("#strobie").css("background-color", getRandomColor());
});

function getRandomColor() {
    var random = Math.round(0xffffff * Math.random());
    return ('#0' + random.toString(16)).replace(/^#0([0-9a-f]{6})$/i, '#$1');
}

function itIsAprilFoolsDay() {
    var today = new Date();
    return today.getMonth() == 3 && today.getDate() == 1;
}

</evil_grin>

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: