First maintenance button in web-interface.

This commit is contained in:
Pecusx
2017-10-10 21:27:05 +02:00
committed by GitHub
parent 1ff6e59c89
commit 03263d9617
2 changed files with 13 additions and 0 deletions
+10
View File
@@ -33,6 +33,16 @@ if (isset($msg)) {
echo " window.location.href = 'index.html';\r\n";
echo "}, 30000);\r\n";
echo "</script>\r\n";
} elseif ($msg == "clear_caches") {
$end = shell_exec('sudo ./scripts/clear_caches.sh');
echo "Clear logs and caches.<br>\r\n";
echo "Wait!<br>\r\n";
echo "<script>\r\n";
echo "// redirect to main after 5 seconds\r\n";
echo "window.setTimeout(function() {\r\n";
echo " window.location.href = 'index.html';\r\n";
echo "}, 5000);\r\n";
echo "</script>\r\n";
} elseif ($msg == "audio") {
$selected = $_POST['output'];
$hda = $_POST['hda'];