From f1ba072f45753074676daf5abc54a1ce28d9e650 Mon Sep 17 00:00:00 2001 From: klarkxy <278370456@qq.com> Date: Sat, 10 May 2025 15:40:44 +0800 Subject: [PATCH] =?UTF-8?q?=E7=A7=BB=E9=99=A4bbcode=5Fto=5Fhtml=E8=AF=95?= =?UTF-8?q?=E8=AF=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- web/template/syzoj/problem.php | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/web/template/syzoj/problem.php b/web/template/syzoj/problem.php index 22ee42c..dd1a2bd 100644 --- a/web/template/syzoj/problem.php +++ b/web/template/syzoj/problem.php @@ -122,7 +122,7 @@ if ($pr_flag) { function trans_md($str) { $s = $str; - $s = bbcode_to_html($s); + // $s = bbcode_to_html($s); if ( strpos($s, "class='md") === false && strpos($s, "class=\"md") === false @@ -148,15 +148,15 @@ if ($pr_flag) { // echo $row['description']; echo trans_md($row['description']); if (isset($_SESSION[$OJ_NAME . '_' . 'administrator']) || isset($_SESSION[$OJ_NAME . '_' . "p" . $row['problem_id']])) { - // Only administrators or problem managers can see the source code toggle + // 管理员增加一个显示源数据 echo '
- ' . $MSG_ADMIN_ONLY . ' - ' . $MSG_DESCRIPTION . ' ' . $MSG_SOURCE_CODE . ' + Markdown原文
' . 
-                  htmlspecialchars($row['description'], ENT_QUOTES, 'UTF-8') . 
+                  $row['description'] .
                 '
';