mirror of
https://github.com/hexahigh/games.git
synced 2025-12-11 20:15:38 +01:00
update base64
This commit is contained in:
parent
eb97f9919f
commit
89952d30e2
@ -5,7 +5,7 @@
|
|||||||
</head>
|
</head>
|
||||||
<noscript>
|
<noscript>
|
||||||
<div style="width: 100%; height: 100%; background-color: #ffffff; color: #27282c;">
|
<div style="width: 100%; height: 100%; background-color: #ffffff; color: #27282c;">
|
||||||
<h1>You seem to have </h1>
|
<h1>You seem to have javascript disabled.<br> This page will not work.</h1>
|
||||||
</div>
|
</div>
|
||||||
</noscript>
|
</noscript>
|
||||||
|
|
||||||
@ -36,36 +36,40 @@
|
|||||||
setTimeout(resolve, milliseconds);
|
setTimeout(resolve, milliseconds);
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
//Copies the text from the output
|
||||||
function docopy() {
|
function docopy() {
|
||||||
document.getElementById("output").select();
|
document.getElementById("output").select();
|
||||||
document.execCommand('copy');
|
document.execCommand('copy');
|
||||||
copytext()
|
copytext()
|
||||||
}
|
}
|
||||||
|
//Takes care of the encoding
|
||||||
function doencode() {
|
function doencode() {
|
||||||
var output = btoa(document.getElementById("input").value)
|
var output = btoa(document.getElementById("input").value)
|
||||||
document.getElementById("output").value = output;
|
document.getElementById("output").value = output;
|
||||||
encodetext()
|
encodetext()
|
||||||
}
|
}
|
||||||
|
//Takes care of the decoding
|
||||||
function dodecode() {
|
function dodecode() {
|
||||||
var output = atob(document.getElementById("input").value)
|
var output = atob(document.getElementById("input").value)
|
||||||
document.getElementById("output").value = output;
|
document.getElementById("output").value = output;
|
||||||
decodetext()
|
decodetext()
|
||||||
}
|
}
|
||||||
|
//How long the text will appear in milliseconds
|
||||||
|
const textTime = 750
|
||||||
|
|
||||||
async function copytext() {
|
async function copytext() {
|
||||||
document.getElementById("copy").innerHTML = "Copied!"
|
document.getElementById("copy").innerHTML = "Copied!"
|
||||||
await delay(500)
|
await delay(textTime)
|
||||||
document.getElementById("copy").innerHTML = "Copy"
|
document.getElementById("copy").innerHTML = "Copy"
|
||||||
}
|
}
|
||||||
async function encodetext() {
|
async function encodetext() {
|
||||||
document.getElementById("encodebutton").innerHTML = "Encoded!"
|
document.getElementById("encodebutton").innerHTML = "Encoded!"
|
||||||
await delay(500)
|
await delay(textTime)
|
||||||
document.getElementById("encodebutton").innerHTML = "Encode"
|
document.getElementById("encodebutton").innerHTML = "Encode"
|
||||||
}
|
}
|
||||||
async function decodetext() {
|
async function decodetext() {
|
||||||
document.getElementById("decodebutton").innerHTML = "Decoded!"
|
document.getElementById("decodebutton").innerHTML = "Decoded!"
|
||||||
await delay(500)
|
await delay(textTime)
|
||||||
document.getElementById("decodebutton").innerHTML = "Decode"
|
document.getElementById("decodebutton").innerHTML = "Decode"
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user