<?php

	include("../M0/session_start.php") ;

	include("../M0/communs_en_tete_HTML.html") ;
	
	$back_link = "../M6/dexin.php";
	include('../M0/communs_en_tete_home_back.html');

	include('../M0/display_user_only.php'); 

?>

<table align="center" width="<?php echo $tables_width ; ?>"  border="2" cellspacing="2" cellpadding="2" bordercolor="#ffffff" bgcolor="#000033">

	<form name="form2" id="form2" method="post" action="">
		
		<tr align="center">
			<td colspan="2">
			
				<table width="98%">
				
					<tr align="center">
						<td>
							<div style="margin-top:10px;margin-bottom:10px;">
							<label 
								class="label_titres_menus" 
								style="font-size:21px;"
							>
								<u>- gestion du serveur SSH -</u>
							</label>
							</div>
						</td>
					</tr>
				</table>
			
				<table width="98%" align="center">
				
					<tr>
						<td align="center" colspan="2">
						
							<div><p>
							<input type="radio" id="SSH_STATUS" name="SSH_ACTION" value="status" checked >
							<label for="SSH_STATUS">status</label>
							&nbsp;&nbsp;
							<input type="radio" id="SSH_START" name="SSH_ACTION" value="start">
							<label for="SSH_START">start</label>
							&nbsp;&nbsp;
							<input type="radio" id="SSH_RESTART" name="SSH_ACTION" value="restart">
							<label for="SSH_RESTART">restart</label>
							&nbsp;&nbsp;
							<input type="radio" id="SSH_RELOAD" name="SSH_ACTION" value="reload">
							<label for="SSH_RELOAD">reload</label>
							&nbsp;&nbsp;
							<input type="radio" id="SSH_STOP" name="SSH_ACTION" value="stop">
							<label for="SSH_STOP">stop</label>
							</p></div>
							
						</td>
					</tr>
					
					<tr>
						<td align="center" colspan="2">
						
							<?php
								echo( '<input type="submit" onclick="my_confirm_function()" value="appliquer" class="button_A" >' ) ;
							?>
								
						</td>
					</tr>
					
				</table>
				
				<font size="1" face="Arial, Helvetica, sans-serif">&nbsp;</font>
				
			</td>
		</tr>
		
	</form>

</table>


<script>

function my_confirm_function() {
	var msg="confirmez-vous cette action sur le serveur SSH ?";
	var txt;

	if (document.getElementById("SSH_STATUS").checked) {
		txt = "./SSH_target_execute.php";
	}
	else {
		var r = confirm(msg);
		if (r == true) {
			txt = "./SSH_target_execute.php";
		} else {
			txt = "./SSH_target.php";
		}
	}
	document.getElementById("form2").action = txt;


}

</script>


 </body>
</html>