mirror of
https://github.com/logicog/RTLPlayground.git
synced 2026-08-30 14:52:51 +08:00
Web-If: Add Console-Cmd input
This commit is contained in:
@@ -27,6 +27,20 @@ async function ipSub() {
|
||||
}
|
||||
}
|
||||
|
||||
async function cmdSub() {
|
||||
var cmd = document.getElementById('console_cmd').value;
|
||||
try {
|
||||
const response = await fetch('/cmd', {
|
||||
method: 'POST',
|
||||
body: cmd
|
||||
});
|
||||
console.log('Completed!', response);
|
||||
} catch(err) {
|
||||
console.error(`Error: ${err}`);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
async function sendConfig(c) {
|
||||
const form = new FormData();
|
||||
form.append("MAX_FILE_SIZE", "4096");
|
||||
|
||||
Reference in New Issue
Block a user