Created
July 7, 2011 19:52
-
-
Save dkordik/1070385 to your computer and use it in GitHub Desktop.
Check to see if Twitter is back up. I use it to let me know when we're no longer rate-limited and I can get back to working on Twitter stuff.
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
i = setInterval(function () { | |
jQuery.ajax({ | |
url: 'http://twitter.com/users/show_for_profile.json?screen_name=dkordik', | |
complete: function (data) { | |
if (JSON.parse(data.responseText)["error"]==undefined) { | |
alert("IT'S BACK BABY!"); //brings focus to the twitter tab! | |
clearInterval(i); | |
location.reload(); | |
} else { | |
console.log("TWITTER? ", JSON.parse(data.responseText)["error"], " " + Date().toString()); | |
} | |
} | |
}); | |
}, 60000); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment