Update 20200925

This commit is contained in:
jomjol
2020-09-25 08:42:45 +02:00
parent 0868c22ac6
commit a08144cc9f
15 changed files with 392 additions and 25 deletions

View File

@@ -29,12 +29,15 @@ textarea {
<tr><td><h2>Config.ini:</h2></td></tr>
<tr>
<td colspan="3">
<textarea id="inputTextToSave" cols="117" rows="38"></textarea>
<textarea id="inputTextToSave" cols="100" rows="33"></textarea>
</td>
</tr>
<tr>
<td><button class="button" onclick="saveTextAsFile()">Update Config.ini</button></td>
</tr>
<td><button class="button" onclick="saveTextAsFile()">Update Config.ini</button></td>
</tr>
<tr>
<td><button class="button" id="reboot" type="button" onclick="doReboot()">Reboot to activate updates</button></td>
</tr>
</table>
<script type="text/javascript" src="./gethost.js"></script>
@@ -59,6 +62,17 @@ function saveTextAsFile()
FileSendContent(textToSave, "/config/config.ini", basepath);
}
}
function doReboot() {
if (confirm("Are you sure you want to reboot the ESP32?")) {
var stringota = "/reboot";
window.location = stringota;
window.location.href = stringota;
window.location.assign(stringota);
window.location.replace(stringota);
}
}
LoadConfigNeu();