alpha_full/menu/menuFamilles.reqFamilles.php
2026-04-06 22:58:51 +02:00

32 lines
1.2 KiB
PHP
Executable File

<?php
$nomFicAppelant = basename(__FILE__);
// ---------------------------------------------------
// recherche des libelles categories ( ancien familles )
// ---------------------------------------------------
$tabFam=array();
$tabFamId=array();
$reqSelect="SELECT F.idFam, F.lienImageWeb, F.afficher, FL.libelle FROM familles AS F JOIN familleslibelle AS FL ON F.idFam =FL.idFam WHERE F.status=1 AND FL.idlg=:lg;";
if (isset($debug[2]) && $debug[2] == '1' ) { $debugMsg .= monDebug (2, ['reqSelect' => $reqSelect], 'menuFamilles.reqFamilles.php');}
try {
$stmt = $idPdo->prepare($reqSelect);
$stmt->bindValue(':lg', $lg, PDO::PARAM_STR);
$stmt->execute();
$f = 0;
while ($result = $stmt->fetch(PDO::FETCH_ASSOC)) {
$tabFamId[$f] = $result['idFam'];
$tabFam[$f] = $result['libelle'];
$tabLienImageWeb[$f] = $result['lienImageWeb'];
$tabAfficherFam[$f] = $result['afficher'];
$f++;
}
} catch (PDOException $e) {
if (isset($debug[2]) && $debug[2] == '1' ) { $debugMsg .= monDebug (2, ['Erreur SQL' => $e->getMessage() ], 'menuFamilles.reqFamilles.php');}
}
$_SESSION['tabFamId']=$tabFamId;
$_SESSION['tabFam']=$tabFam;
$idFamForMenu=0;
$pair=0;
?>