formulaire pour remplir des ticket de panne
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 

45 lines
1.4 KiB

<?php
include '../session_restraintes.php';
$bdd = new PDO('mysql:host=localhost;dbname=ticket;charset:utf8', 'root', '');
$reponse = $bdd->query("SELECT * FROM logins");
$arr = [];
while ($line = $reponse->fetch()) {
$arr[$line[0]] = $line[1];
}
$reponse->closeCursor();
?>
<html>
<head>
<?php include 'include/menu.php'; ?>
<script type="text/javascript" src="js/admin.js" defer></script>
</head>
<body>
<?php include 'include/nav.php'; ?>
<table>
<thead>
<tr>
<th colspan="3">Mot de passe</th>
</tr>
</thead>
<tbody>
<tr class='table-title'>
<td>Login</td>
<td>Password</td>
</tr>
<tr>
<?php
foreach ($arr as $key => $value) {
echo '<tr>
<td class=',$key,' style="font-weight: bold;">', $key,'</td>
<td class=',$key,'>', $value,'</td>
<td class=',$key,'><input class="edit" type="button" value="edit" onclick="Edit(\'',$key,'\')"></td>
</tr>';
}
?>
</tr>
</tbody>
</table>
</body>
</html>