فهرست منبع

修改html标签问题

llp 5 روز پیش
والد
کامیت
557087287c
1فایلهای تغییر یافته به همراه2 افزوده شده و 2 حذف شده
  1. 2 2
      config/purify.php

+ 2 - 2
config/purify.php

@@ -42,9 +42,9 @@ return [
         'default' => [
             'Core.Encoding'            => 'utf-8',
             'HTML.Doctype'             => 'HTML 4.01 Transitional',
-            'HTML.Allowed'             => 'h1,h2,h3,h4,h5,h6,b,u,strong,i,em,s,del,a[href|title],ul,ol,li,p[style],br,span[style],img[width|height|alt|src],blockquote',
+            'HTML.Allowed'             => 'h1,h2,h3,h4,h5,h6,b,u,strong,i,em,s,del,a[href|title],ul,ol,li,p[style],br,span[style],img[width|height|alt|src|style],blockquote,table[style],caption,thead[style],tbody[style],tfoot[style],tr[style],td[colspan|rowspan|style],th[colspan|rowspan|style],div[style|class],video[src|controls|width|height|poster],source[src|type]',
             'HTML.ForbiddenElements'   => '',
-            'CSS.AllowedProperties'    => 'font,font-size,font-weight,font-style,font-family,text-decoration,padding-left,color,background-color,text-align',
+            'CSS.AllowedProperties'    => 'font,font-size,font-weight,font-style,font-family,text-decoration,padding-left,color,background-color,text-align,width,height,border,border-collapse,vertical-align,margin,margin-left,margin-right,float',
             'AutoFormat.AutoParagraph' => false,
             'AutoFormat.RemoveEmpty'   => false,
         ],