htmlentities -> htmlspecialchars

This commit is contained in:
2024-12-06 15:35:38 +08:00
parent daa005f029
commit d9b2d13caa
184 changed files with 410 additions and 405 deletions

View File

@@ -43,13 +43,13 @@ function pdo_query($sql){
}catch(PDOException $e){
// echo "<span class=red>".$e->getMessage()."</span>"; // open this line to debug SQL fail problems
// $view_errors="SQL:".$sql."\n".$e->getMessage();
// echo htmlentities($view_errors."\n\n");
// echo htmlspecialchars($view_errors."\n\n");
GLOBAL $MSG_UPDATE_DATABASE,$MSG_HELP_UPDATE_DATABASE;
GLOBAL $POP_UPED,$OJ_NAME,$_SESSION;
if(!$POP_UPED&&isset($_SESSION[$OJ_NAME.'_administrator'])){
echo " $MSG_HELP_UPDATE_DATABASE <a href='/admin/update_db.php'>$MSG_UPDATE_DATABASE</a>。";
$view_errors="SQL:".$sql."\n".$e->getMessage();
echo htmlentities($view_errors."\n\n");
echo htmlspecialchars($view_errors."\n\n");
$POP_UPED=true;
}