-
Notifications
You must be signed in to change notification settings - Fork 1
/
specialiste copy.php
40 lines (38 loc) · 1.1 KB
/
specialiste copy.php
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
<?php
include_once 'const.php';
global $mysqlConnection;
$memberStatement = $mysqlConnection->prepare("SELECT * FROM Medecin JOIN Specialite ON Medecin.spe = Specialite.ID_spe JOIN Plage_horraire ON Medecin.ID = Plage_horraire.ID_Medecin WHERE Medecin.spe != '0';");
$memberStatement->execute();
$result = $memberStatement->fetchAll();
$memberStatement = $mysqlConnection->prepare("SELECT * FROM Specialite ;");
$memberStatement->execute();
$spe = $memberStatement->fetchAll();
echo('<div id="contenantSpe">');
$temp = false;
include 'card.php';
foreach($spe as $specialite)
{
foreach($result as $res)
{
if($res["spe"] == $specialite["ID_spe"])
{
$temp = true;
}
}
if($temp == true)
{
echo ('<div id="deroulantSpe">');
echo ('<div class="titreSpe">');
echo($specialite["Nom_spe"]);
echo ('</div>');
foreach ($result as $elem) {
if($elem["spe"] == $specialite["ID_spe"])
{
card($elem);
}
}
echo ('</div>');
}
$temp = false;
}
echo ('</div>');