23 lines
1.1 KiB
PHP
Executable File
23 lines
1.1 KiB
PHP
Executable File
<?php
|
|
$nomFicAppelant = basename(__FILE__);
|
|
|
|
// -----------------------------------------------------
|
|
// Update page
|
|
// -----------------------------------------------------
|
|
|
|
if (!empty($theDescPage)) $theDescPage = addslashes($_POST['theDescPage']);
|
|
if (!empty($theNomPage)) $theNomPage = addslashes($theNomPage);
|
|
$theDescPage = htmlspecialchars($theDescPage, ENT_QUOTES,"UTF-8",false);
|
|
$theNomPage = htmlspecialchars($theNomPage, ENT_QUOTES,"UTF-8",false);
|
|
$reqUpdate = "UPDATE `pages` SET description='" .$theDescPage. "', nom='" .$theNomPage. "' WHERE id=" .$theIdPage. " and codeLangue='" .$lg. "';";
|
|
$result='';
|
|
if (isset($debug[2]) && $debug[2] == '1') { $debugMsg .= monDebug(2, ['reqUpdate' => $reqUpdate], 'pageReqUpdate.php');}
|
|
$resConn=$idPdo->query($reqUpdate) ;
|
|
if ($resConn) {
|
|
$admMsg .= 'La base de données a été mise à jour '; if (isset($_SESSION['lgCouranteLibelle'])) $admMsg .='pour la langue : ' .$_SESSION['lgCouranteLibelle'];
|
|
$admMsgClass='ok';
|
|
}
|
|
else {
|
|
if (isset($debug[2]) && $debug[2] == '1' ) {$admMsg .= 'Erreur lors de la mise à jour de la base de données'; $admMsgClass='ko'; }
|
|
}
|
|
?>
|