</div> <div class="one-third column"> <?php write_link("aria2-restart.php", "(Re)start Aria2"); ?> <p>You can force a restart of the Aria2 server</p> </div> <div class="one-third column"> <?php write_link("aria2-stop.php", "Stop Aria2"); ?> <p>You can force a stop of the Aria2 server</p> </div> <div class="one-third column"> <?php write_link("fix-usb.php", "Force recheck USB bus"); ?> <p>You can force a scan of the USB bus</p> </div> --> <!-- for some actions, it is important to avoid having a dedicated page otherwise if the user reloads that page, it will trigger again an action that is often not wanted. E.g., if you open the reboot page, a reboot will be issued; by clicking the browser "refresh" button another reboot would be issued!! --> <div class="one-third column"> <?php write_php_action_with_confirm("do_shutdown", "Shutdown", "Are you really sure to shutdown the " . $PORTAL_NAME . "?");
function write_var($path, $info, $prefix) { global $globals, $error; $error = false; $org = set_error_handler('witness_error_handler'); $var = unserialize($info['value']); set_error_handler($org); $params = array('name' => $info['name'], 'value' => $error === false ? $var : $info['value'], 'globals' => $globals); $file = $prefix . '_' . (isset($info['call']) === true ? $info['call'] . '_' : '') . $info['name'] . '.html'; if (write_html($params, 'var.template.php', "{$path}/var/{$file}") === false) { return null; } return write_link($file, $params['name'], $params['value']); }
<h3> <?php write_link("index.php", "Go back to home"); ?> </h3>