Les Associés Supporters sont présents dans la plupart des départements au travers de ses 220 sections.. Cliquer sur votre département pour retrouver les sections proches de chez vous.
|
<?php if(isset($_GET['dept'])) { $db =& JFactory::getDBO(); $sql = "SELECT * FROM sections WHERE dep='".$_GET['dept']."'"; $db->setQuery($sql); $list = $db->loadObjectList(); if ($list) { $sql = "SELECT num, nom, site, mail FROM sections WHERE dep='".$_GET['dept']."'"; $db->setQuery($sql); $nb_sections= $db->getNumRows();; if($nb_sections==1) { echo "<h4>Département ".$_GET['dept']."</h4>"; } if($nb_sections>1) { echo "<h4>Les sections dans le ".$_GET['dept']."</h4><br/>"; foreach ($list as $item) { echo "<div style='line-height:20px;'>"; echo "<a href='sections.php?num=".$item->num."'>".$item->num." ".$item->nom."</a>"; if(!empty($sections['site'])) { echo " <a onclick=\"window.open(this.href, '_blank'); return false;\" href='http://".$item->site."'><img style='margin-bottom:-3px;' src='img/www.gif' alt='Site Internet' /></a>"; } if(!empty($item->mail)) { echo " <a href='mailto:".$item->mail."'><img style='margin-bottom:-3px;' src='img/email.gif' alt='Email' /></a>"; } echo "</div>"; } } else { echo "<h3>Nous n'avons pas encore de sections dans le ".$_GET['dept']."</h3>"; } } } ?> |