From 5d7c1b955b4d7632f667b9d28e6dfcebc2e1dbec Mon Sep 17 00:00:00 2001 From: Jacob Janzen Date: Sun, 28 Apr 2024 15:38:17 -0500 Subject: add test script --- scripts/webring.js | 12 ++++++++++++ 1 file changed, 12 insertions(+) create mode 100644 scripts/webring.js (limited to 'scripts/webring.js') diff --git a/scripts/webring.js b/scripts/webring.js new file mode 100644 index 0000000..2b08b77 --- /dev/null +++ b/scripts/webring.js @@ -0,0 +1,12 @@ +const xhr = new XMLHttpRequest(); + +xhr.open("GET", "https://aidang.cc/webring/all") +xhr.send(); +xhr.responseType("json"); +xhr.onload = () => { + if (xhr.readyState == 4 && xhr.status == 200) { + console.log(xhr.response); + } else { + console.log(`Error: ${xhr.status}`); + } +} -- cgit v1.2.3