diff --git a/ruoyi-common/src/main/java/com/ruoyi/common/utils/HtmlUtils.java b/ruoyi-common/src/main/java/com/ruoyi/common/utils/HtmlUtils.java index 88fc1bd..de34ed2 100644 --- a/ruoyi-common/src/main/java/com/ruoyi/common/utils/HtmlUtils.java +++ b/ruoyi-common/src/main/java/com/ruoyi/common/utils/HtmlUtils.java @@ -33,13 +33,13 @@ public class HtmlUtils { text = text.replaceAll(""", "\""); text = text.replaceAll("'", "'"); text = text.replaceAll("'", "'"); - text = text.replaceAll("—", "—"); - text = text.replaceAll("–", "–"); - text = text.replaceAll("…", "…"); - text = text.replaceAll("“", """); - text = text.replaceAll("”", """); - text = text.replaceAll("‘", "'"); - text = text.replaceAll("’", "'"); + text = text.replaceAll("—", "\u2014"); + text = text.replaceAll("–", "\u2013"); + text = text.replaceAll("…", "\u2026"); + text = text.replaceAll("“", "\u201C"); + text = text.replaceAll("”", "\u201D"); + text = text.replaceAll("‘", "\u2018"); + text = text.replaceAll("’", "\u2019"); text = text.replaceAll("\\r\\n", "\n"); text = text.replaceAll("\\r", "\n"); text = text.replaceAll("\\n\\n+", "\n\n");