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 51 52 53 54 55 56 57 58 59 60 61
| <?php
echo "<b>Inscriptions de l'école : $_POST[ecole]</b><br/><br/>";
if ( isset ($_POST['ecole']))
{
$resec = mysql_query("SELECT ecole, nom, prenom, anim_ob, anim_ci, anim_dv, projet FROM jos_ecole_animation WHERE ecole='$_POST[ecole]'") OR die("impossible");
echo "<table width='100%' border='1' cellpadding='1' cellspacing='1' align='center'>
<tr>
<td><b>Nom</b></td>
<td><b>Prénom</b></td>
<td><b><center>Animation 1</center></b></td>
<td><b><center>Animation 2</center></b></td>
<td><b><center>Animation 3</center></td>
</tr>";
while ($row=mysql_fetch_array($resec))
{
$projet=$row[projet];
$rowanimob=$row[anim_ob];
$rowanimob = addslashes($rowanimob);
$rowanimci=$row[anim_ci];
$rowanimci = addslashes($rowanimci);
$rowanimdv=$row[anim_dv];
$rowanimdv = addslashes($rowanimdv);
$sql = mysql_query("SELECT date_format(date_1ob,'%d-%m-%y')AS date1ob, date_format(date_2ob,'%d-%m-%y')AS date2ob FROM jos_ecole_animob WHERE animob='$rowanimob'") OR DIE ("IMPOSSIBLE SQL");
If ( isset($rowanimob))
{
while ($rows=mysql_fetch_array($sql))
{$date1ob = $rows[date1ob];
$date2ob = $rows[date2ob];}
}
$sql1 = mysql_query("SELECT date_format(date_1,'%d-%m-%y')AS date1ci, date_format(date_2,'%d-%m-%y')AS date2ci FROM jos_ecole_anim_ci WHERE anim = '$rowanimci'") OR DIE ("IMPOSSIBLE1");
If ( isset($rowanimci))
{
while ($rows1=mysql_fetch_array($sql1))
{$date1ci = $rows1[date1ci];
$date2ci = $rows1[datecib];}
}
$sql2 = mysql_query("SELECT date_format(date_1,'%d-%m-%y')AS date1dv, date_format(date_2,'%d-%m-%y')AS date2dv FROM jos_ecole_anim_dv WHERE anim_dv = '$rowanimdv'") OR DIE ("IMPOSSIBLE2");
If ( isset($rowanimdv))
{
while ($rows2=mysql_fetch_array($sql2))
{$date1dv = $rows2[date1dv];
$date2dv = $rows2[date2dv];}
}
echo"<tr><td>$row[nom]</td><td>$row[prenom]</td><td><center>$rowanimob<br/>$date1ob et $date2ob</center></td><td><center>$rowanimci<br/>$date1ci et $date2ci</center></td><td><center>$rowanimdv<br/>$date1dv et $date2dv</center></td><tr>";
}
echo "</table>";
}
echo "<br/>";
echo "Projet d'école : $projet";
echo "<br/>";
?> |
Partager