alpha_full/admin/options/langues/langues.reqUpdateLg.php
2026-04-06 22:58:51 +02:00

29 lines
1.5 KiB
PHP
Executable File

<?php
$nomFicAppelant = basename(__FILE__);
$resConn='';
if (!empty($theLibLg)) if ($theLibLg!="") $theLibLg=addslashes($theLibLg);
if ($theLibLg!="") $theLibLg=htmlspecialchars($theLibLg, ENT_QUOTES,"UTF-8",false);
if (!empty($theTitle)) if ($theTitle!="") $theTitle=addslashes($theTitle);
if ($theTitle!="") $theTitle=htmlspecialchars($theTitle, ENT_QUOTES,"UTF-8",false);
if (!empty($theAlt)) if ($theAlt!="") $theAlt=addslashes($theAlt);
if ($theAlt!="") $theAlt=htmlspecialchars($theAlt, ENT_QUOTES,"UTF-8",false);
$reqUpdate="UPDATE `codeslangueslibelle` SET ";
if (!empty($theLibLg)) {$reqUpdate .= "libelle='" .$theLibLg. "', ";}
if (!empty($theAlt)) {$reqUpdate .= "drapeauAlt='" .$theAlt. "', ";}
if (!empty($theTitle)) {$reqUpdate .= "drapeauTitle='" .$theTitle. "', ";}
if (!empty($theLien)) {$reqUpdate .= "drapeauLien='" .$theLien. "' ";}
// if (!empty($theCode2)) {$reqUpdate .= "idLg='" .$theCode2. "' ";}
$rest = strlen($reqUpdate)-2;
$reqUpdate=substr($reqUpdate,0,$rest);
$resConn='';
$reqUpdate .= " WHERE idLg='" .$theCode. "' and id=" .$theIDLg. " ;";
$resConn=$idPdo->query($reqUpdate);
if (isset($debug[2]) && $debug[2] == '1' ) { $debugMsg .= monDebug(2, ['reqUpdate' => $reqUpdate], 'langues.reqUpdateLg.php');}
if ($resConn) {$admMsg .= "Mise à jour libellé langue effectuée avec succès !"; $admMsgClass='ok';
}
else {$admMsg .= "Echec de la mise à jour libellé langue."; $admMsgClass='ko'; }
?>