Project

General

Profile

« Previous | Next » 

Revision 6073137f

Added by sbeaver over 10 years ago

Updated for consistency with reboot.php

Updated for consistency with reboot.php

View differences:

usr/local/www/halt.php
58 58
$pgtitle = array(gettext("Diagnostics"),gettext("Halt system"));
59 59
include('head.inc');
60 60

  
61
if (stristr($_POST['Submit'], gettext("Yes"))) {
62
	?><meta http-equiv=\"refresh\" content=\"70;url=/\"> <?php
63
	print('<div class="alert alert-success" role="alert">'.gettext("The system is halting now. This may take one minute or so.").'</div>');
61
if ($_SERVER['REQUEST_METHOD'] == 'POST') {
62
?>
63
	<meta http-equiv="refresh" content="70;url=/">
64
	<div class="alert alert-success" role="alert">
65
		<?=gettext("The system is halting now. This may take one minute or so.")?>
66
	</div>
64 67

  
68
<?php
65 69
	if(DEBUG)
66 70
	   print("Not actually halting (DEBUG is set true)<br>");
67 71
	else
68 72
		system_halt();
69 73
} else {
70

  
71

  
72 74
?>
73 75

  
74
<!-- Simple HTML version -->
75 76
<div class="panel panel-default">
76 77
	<div class="panel-heading">Are you sure you want to halt the system?</div>
77
		<div class="panel-body">Click "Yes" to halt the system immediately, or "No" to go to the system dashboard. (There will be a brief delay before the dashboard appears.)<br /><br />
78
			<form action="halt.php" method="post">
79
				<input type="submit" class="btn btn-danger pull-center" name="Submit" value="Yes">
80
				<input type="submit" class="btn btn-default" name="Submit" value="No">
81
			</form>
82
		</div>
78
	<div class="panel-body">Click "Yes" to halt the system immediately, or "No" to go to the system dashboard. (There will be a brief delay before the dashboard appears.)<br /><br />
79
		<form action="halt.php" method="post">
80
			<input type="submit" class="btn btn-danger pull-center" name="Submit" value="Yes">
81
			<a href="/" class="btn btn-default">No</a>
82
		</form>
83 83
	</div>
84 84
</div>
85 85

  
86 86
<?php
87 87
}
88
include("foot.inc");
89
?>
90 88

  
89
include("foot.inc");

Also available in: Unified diff