updates to http terminal

This commit is contained in:
2021-06-30 20:33:16 +02:00
parent a0f6a5aec3
commit 66e8ddb2d9
7 changed files with 64 additions and 42 deletions
-12
View File
@@ -1,12 +0,0 @@
<!DOCTYPE html>
<html>
<head>
<title>Ich bin ein komrpimierter Test</title>
I bims der Head
</head>
<body>
I bims der Body
</body>
</html>
+2 -2
View File
@@ -62,9 +62,9 @@
<div class="terminal">
<input type="button" id="clear_term" value="clear" onclick="clearTerminal();">
<input type="checkbox" id="scroll" name="scroll" value="scroll">
<input type="checkbox" id="scroll" name="scroll" value="scroll" checked>
<label for="scroll"> autoscroll </label>
<textarea id="term"> waiting for log messages ... </textarea>
<textarea id="term">waiting for log messages ...&#10;</textarea>
</div>
</body>
+1 -1
View File
@@ -17,7 +17,7 @@ xhr.onreadystatechange = function(){
console.log(xhr.responseText);
terminal = document.getElementById("term");
autoscroll = document.getElementById("scroll");
terminal.innerHTML += xhr.responseText + '\n';
terminal.innerHTML += xhr.responseText;
if(autoscroll.checked)
terminal.scrollTop = terminal.scrollHeight;
}
+1 -1
View File
@@ -116,7 +116,7 @@ input:checked + .slider:before {
#term {
font-size: large;
width: 100%;
height: 10em;
height: 20em;
}
#clear_term {