effacer par checkbox dans un formulaire
slt je voudrais effacer des membre de ma base de données en cochant un ou plusieurs membres puis en cliquant sur submir,y a t'il des idees merciiiiiiiii
Code:
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50
|
<html>
<head>
<style type="text/css">
<!--
.Style1 {color: #000000}
-->
</style>
</head>
<body link="#00CCFF" vlink="#00CCFF" text="#FFFFF" bgcolor="#000000" alink="#00CCFF">
<?php
include_once("db_connect.php");
$requete="select pseudo,email,prenom from gx_user where statut not like 'admin'";
$rep=mysql_query($requete);
if($rep==0)
print("table membre vide<br>");
else
{
echo "<form name=form method=post>";
echo "<center><h1><blink>La liste des membres</blink></h1></center>";
echo "<table border=2>";
echo "<tr><th>pseudo</th><th>mail</th><th>prenom</th><th>Effacer</th></tr>";
$id=0;
while($ligne=mysql_fetch_row($rep))
{
$id++;
$var0=$ligne[0];
$var1=$ligne[1];
$var2=$ligne[2];
echo "<tr><th>$var0</th><th>$var1</th><th>$var2</th><th><input type=\"checkbox\" name=".$id." ></th></tr>";
}
echo "</table>";
echo "<input type=submit name=suppression value=effacer>";
echo "</form>";
}
?>
<p align="center"><a href="admin.php"><img src="gifs/retour.gif" width="107" height="43"></a></p>
</body>
</html> |