Skip to content

Instantly share code, notes, and snippets.

@wkliwk
Created November 17, 2019 12:33
Show Gist options
  • Save wkliwk/77ea268814f30575271a410667b28d5d to your computer and use it in GitHub Desktop.
Save wkliwk/77ea268814f30575271a410667b28d5d to your computer and use it in GitHub Desktop.
(bookmarklets) for voting HKer to be TIME's Person of the Year for 2019
javascript: (function () {
const t = new XMLHttpRequest;
t.open("POST", "https://time-magazine-production.herokuapp.com/api/vote"), t.setRequestHeader("Content-Type", "application/json"), t.onload = function () {
200 === t.status ? alert("成功\n光復香港,時代革命") : alert("錯誤")
}, t.send(JSON.stringify({
person_id: "54",
result: !0,
fingerprint: (t => {
const e = `; ${document.cookie}`.split(`; ${t}=`);
if (2 === e.length) return e.pop().split(";").shift()
})("fingerprint"),
email: "false"
}))
}());
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment