<?php
	// On prolonge la session
	session_start();

	// On teste si la variable de session existe et contient une valeur
	if(empty($_SESSION['login'])) {
		
		// Si inexistante ou nulle, on redirige vers le formulaire de login
		header('Location: /login.php');
		exit();
		
	} else {
		
		include ("../_identifiants/sql_identification_main.php");
		include ("./get_AQCM05_sites.php");
		$sites_id_strings = $sites_from_AQCM05_SITES_LIST ;
		
	}
?>

<?php
	include("../M0/communs_en_tete_HTML.html") ;
?>
    
<font size="1" face="Arial, Helvetica, sans-serif">&nbsp;</font>

<div align="center">
		
	<form name="form1" method="post" action="./index_1.php">
	<table width="<?php echo $tables_width ; ?>"  border="2" cellspacing="2" cellpadding="2" bordercolor="#ffffff" bgcolor="#000033">	
		
		
		<tr align="left">
			<td>
				<div><p>
					<table>
					
						<tr>
							<td align="right" width="165">
								<label>
									<font size="4" color="white" face="Arial, Helvetica, sans-serif">
										utilisateur :
									</font>
								</label>
							</td>
							<td align="left">
								<input disabled name="aqcm_USER" id="aqcm_USER" type="text" maxlength="6" value="<?php echo($_SESSION['login']);?>" size="28" class="txtField" >
							</td>
						</tr>

						<tr>
							<td align="right">
								<label>
									<font size="4" color="white" face="Arial, Helvetica, sans-serif">
										identifiant du site :
									</font>
								</label>
							</td>
							<td align="left">
								<input disabled name="aqcm_SITE_ID" id="aqcm_SITE_ID" type="text" maxlength="6" value="<?php echo($_SESSION['SITE_ID']);?>" size="28" class="txtField" >
							</td>
						</tr>

					</table>
				</p></div>
			</td>
		</tr>

		<tr align="center">
			<td colspan="2">
			
				<table width="490">
				
					<?php
						if ( $_SESSION['level'] > 5 ) {
							include("./bandeau_administrateur.html") ;
						}						;
					?>
				
					<?php
						if ( $_SESSION['level'] > 5 ) {
							include("./create_user.php") ;
						}						;
					?>
				
					<?php
						if ( $_SESSION['level'] >= 90 ) {
							include("./create_site.php") ;
						}						;
					?>
				
				</table>

				
			</td>
		</tr>
				
		<tr align="center" bordercolor="#666666">
			<td>

				<table>
				
					<tr align="center">
						<td align="center" colspan="2">
							<label>
							<font size="4" color="white" face="Arial, Helvetica, sans-serif">
								<p>
									consulter les mesures
								</p>
							</label>
							</font>						
						</td>
					</tr>
							


				</table>

				</br>

				<div align="center">
					<input type="submit" style="font-family: sans-serif; font-size: 18px; name="lancer" value=" &nbsp;&nbsp;&nbsp;choisir ce site &nbsp;&nbsp;&nbsp;">
				</div>
				
				<font size="1" face="Arial, Helvetica, sans-serif">&nbsp;</font>
			</td>
		</tr>
		
	</table>
	</form>
</div>

<p><div>
<?php include('../M0/communs_bouton_retour_index.html'); ?>
</div></p>

    </body>
</html>