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
| At some point in my life I needed to use JQuery's toggle(), show(), and hide() functions but could not use JQuery, so I made claps.js. | |
| I have no idea why anyone else would need this -heck, I can't remember why I needed it-, but here it is anyways. | |
| Enjoy. |
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
| CURRENT (BROKEN - It cannot possibly return a number of players from the API method that returns only true or false based on whether the server is up. The status method doesn't even return data.players) | |
| var ip = "player.server.com"; | |
| var xhr = new XMLHttpRequest(); | |
| xhr.open("GET", "http://minecraft-api.com/v1/status/?server=" + ip, true); | |
| xhr.onreadystatechange = function() { | |
| if (xhr.readyState == 4) { | |
| data = JSON.parse(xhr.responseText); | |
| if (data.status) { |
NewerOlder