Skip to content

Instantly share code, notes, and snippets.

@hfuller
Created August 28, 2022 06:24
Show Gist options
  • Save hfuller/cb06a52939f04724830d38daeb2f19fa to your computer and use it in GitHub Desktop.
Save hfuller/cb06a52939f04724830d38daeb2f19fa to your computer and use it in GitHub Desktop.
ShittyStallionServerStatus.user.js
// ==UserScript==
// @name ShittyStallionServerStatus
// @namespace http://github.com/hfuller
// @version 1
// @description dont even worry about it bro
// @author Hunter Fuller
// @match https://manage.buyvm.net/
// @icon https://www.google.com/s2/favicons?sz=64&domain=buyvm.net
// @grant none
// ==/UserScript==
(function() {
'use strict';
let els = document.getElementsByClassName("dashboard-vm");
for ( let el of els ) {
let vserverid = /[^/]*$/.exec(el.href)[0];
console.log(vserverid);
let x = new FormData();
x.append("vserverid", vserverid);
fetch("https://manage.buyvm.net/ajax/vserver/status", {body: x, method: "POST"}).then((response) => response.json()).then((result) => {
console.log(result);
el.innerHTML = el.innerHTML + " - " + result.status;
});
}
})();
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment