Black Eagle Team Minishell
Path:
/
home
/
c
/
c
/
p
/
ccpsafy
/
www
/
private
/
espace_adherent
/
[
Home
]
File: annuaire_membres.php
<?php include("../../inc/enligne_param.inc.php"); include("../../inc/gere_session.inc.php"); include("../../inc/salutations.inc.php"); ?> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <title>CCPSA Espace adherent - annuaire des membres</title> <link rel="stylesheet" media="screen" type="text/css" href="../../css/common.css" title="common" /> <!--GOOGLE FONTS--> <link href="../css/common.css" rel="stylesheet" type="text/css"> <link href="https://fonts.googleapis.com/css2?family=Source+Sans+Pro:wght@400;600&display=swap" rel="stylesheet"> <!--FIN GOOGLE FONTS--> </head> <body> <div id="page"> <div id="container"> <h2>ANNUAIRE DES ADHÉRENTS</h2> <h5>Interface Administrateur. Session ouverte pour : <?php echo ucfirst($LePrenom).' '.strtoupper($LeNom); ?>.</h5> <hr /> <div id="col_nav"> <?php include("../../inc/menu.inc.php");?> <!-- Code ajouté : DEBUT --> <?php if(isset($_POST['sorting'])) { $sorting = $_POST['sorting']; } else{ //Valeur par défaut $sorting = "ByName"; } ?> <form action="#" method="post"> <p>Classer les membres par :</p> <p> <select name="sorting" id="sorting" onchange="submit()"> <option value="ByName" <?php if ($sorting == "ByName") { echo "selected";}?> >Nom</option> <option value="BySeniority" <?php if ($sorting == "BySeniority") { echo "selected";}?> >Ancienneté</option> <option value="BySeniorityReverse" <?php if ($sorting == "BySeniorityReverse") { echo "selected";}?> >Nouveauté</option> <option value="ByMail" <?php if ($sorting == "ByMail") { echo "selected";}?> >Mail</option> <option value="ByPostalCode" <?php if ($sorting == "ByPostalCode") { echo "selected";}?> >Code Postal</option> <option value="ByFpf" <?php if ($sorting == "ByFpf") { echo "selected";}?> >N° FPF</option> </select> </p> </form> <!-- Code ajouté : FIN --> <hr /> <div id="liensRC"> <?php $query = "SELECT * FROM adherent WHERE actif !='non' ORDER BY nom ASC"; $result = mysql_query($query) or die("Erreur dans l'extraction des informations<br>"); $nbP = mysql_num_rows($result); // Récuperation des résultats if ($nbP==0) { echo "Ooops ! erreur";} else { while ($row = mysql_fetch_array($result)){ $Nom = strtoupper($row['nom']); echo"<a href='#$Nom' class='rclink'> $Nom </a>"; } } ?> <hr /> </div> </div> <div id="col_ABC"> <?php echo"<a name='$Go'></a>"; // Code modifié : DEBUT // Création et envoi de la requetei if ($sorting == "ByName") { $query = "SELECT * FROM adherent WHERE actif !='non' ORDER BY nom, prenom "; } elseif ($sorting == "BySeniority") { $query = "SELECT * FROM adherent WHERE actif !='non' ORDER BY idccpsa ASC"; } elseif ($sorting == "BySeniorityReverse") { $query = "SELECT * FROM adherent WHERE actif !='non' ORDER BY idccpsa DESC"; } elseif ($sorting == "ByMail") { $query = "SELECT * FROM adherent WHERE actif !='non' ORDER BY mail"; } elseif ($sorting == "ByPostalCode") { $query = "SELECT * FROM adherent WHERE actif !='non' ORDER BY cp "; } elseif ($sorting == "ByFpf") { $query = "SELECT * FROM adherent WHERE actif !='non' ORDER BY idfpf ASC"; } // Code modifié : FIN $result = mysql_query($query) or die("Erreur dans l'extraction des informations<br>"); $nbP = mysql_num_rows($result); // Récuperation des résultats if ($nbP==0) { echo "Hum ! c'est ennuyeux, il semble que nous n'ayons pas de donnees a afficher. Ou qu'il y ait une erreur dans leur extraction.";} else { while ($row = mysql_fetch_array($result)){ $Fpf = $row['idfpf']; $Ccpsa = $row['idccpsa']; $Arrive = $row['arrive']; $Civ = ucfirst($row['civ']); $Nom = strtoupper($row['nom']); $Prenom = ucwords($row['prenom']); $Adresse = $row["cp"].' - '.ucfirst($row["commune"]); //$Adresse = $row["num"].', '.ucwords($row["voie"]).'<br/>'.$row["cp"].' - '.ucfirst($row["commune"]); $Tel = $row['tel1']; $Mobile = $row['tel2']; $Lien = $row["mail"]; $Mail = $Lien; $Photo = $row["photo"]; $Apn = ucfirst($row["apn"]); $Style = ucfirst($row["style"]); $Fonction = $row["cat"]; $Definition = $row['definition']; $Activite = $row["activite"]; //Affichage echo "<div id='vignetteH'> <a name='$Nom'></a>"; echo"<p class='pplus'>$Prenom $Nom</p>"; echo"<img src='../trombin/$Prenom $Nom.jpg 'height='150px'/>"; if ( (!is_null($Definition)) && (!empty($Definition)) ) { echo"<p><b>$Definition</b>"; } else { echo "<p> </p>"; } if ( (!is_null($Fonction)) && (!empty($Fonction)) ) { echo" $Fonction<br />"; } if ( (!is_null($Activite)) && (!empty($Activite)) ) { echo"$Activite</p>"; } echo"<p>N° Ccpsa : <strong>".$Ccpsa."</strong> / FPF : <strong>".$Fpf."</strong>"; echo"<br/>Membre depuis ".$Arrive.""; echo"<br/>".$Adresse.""; $Mobile_split = str_replace("\r\n", " ", chunk_split($Mobile, 2)); $Tel_split = str_replace("\r\n", " ", chunk_split($Tel, 2)); echo"<br/>Tél : ".$Tel_split." / ".$Mobile_split.""; echo"<br/><a class='xlink' href=\"mailto:$Lien\">".$Mail."</a>\n</p>"; if ( (!is_null($Apn)) && (!empty($Apn)) ) { echo"<p>$Apn"; } if ( (!is_null($Style)) && (!empty($Style)) ) { echo"<br/>$Style"; } echo"</div>"; } } ?> <br /> </div> <!--fin col ABC--> <hr /> <!--MENU BAS--> <p> |<a href="../../index.php" class="zlink"> accueil </a> |<a href="../../pages/activites.php" class="zlink"> activités </a> |<a href="../../pages/galeries.php" class="zlink"> galeries </a> |<a href="../../pages/liens_utiles" class="zlink"> liens utiles </a> |<a href="../../pages/legal.php" class="zlink"> bureau et légalité </a> |<a href="../admin/index.php" class="zlink"> espace adhérents </a>| </p> <!--FIN MENU BAS--> </div> <!--fin container--> </div> <!--fin page--> </body> </html>
©
2020 Black Eagle Team