浏览代码

文章详情样式修改

xingzai 3 年之前
父节点
当前提交
45b1ef9e87
共有 1 个文件被更改,包括 1 次插入0 次删除
  1. 1 0
      controllers/article.go

+ 1 - 0
controllers/article.go

@@ -93,6 +93,7 @@ func (this *ArticleController) Detail() {
 			return
 		}
 		detail.Body = html.UnescapeString(detail.Body)
+		detail.Body = strings.Replace(detail.Body, "pre", "div", -1)
 		//detail.Abstract = html.UnescapeString(detail.Abstract)
 		detail.Abstract, _ = services.GetReportContentTextSub(detail.Abstract)
 		if companyPermission == "" {