我在将ckeditor
HTML
内容保存到数据库时遇到问题。这是应该保存的
<h2 dir="rtl" style="text-align:center"><strong></strong></h2>
<table border="1" cellpadding="10" cellspacing="0" style="width:100%">
<tbody>
<tr>
<td colspan="2" dir="rtl" style="background-color:#99cc66">
<strong><span style="font-size:20px">:</span></strong>
</td>
</tr>
<tr>
<td> </td>
<td> </td>
</tr>
<tr>
<td> </td>
<td> </td>
</tr>
</tbody>
</table>
这是html
ckeditor
textarea
但是在发送post
和var_dump($_POSt)
之后,它看起来像:
<h2 dir="rtl" [removed]="width:100%">
<tbody>
<tr>
<td colspan="2" dir="rtl" [removed]="font-size:20px">:</span></strong></td>
</tr>
<tr>
<td> </td>
<td> </td>
</tr>
<tr>
<td> </td>
<td> </td>
</tr>
</tbody>
</table>
<p dir="rtl"> </p>
这是我在ckeditor
中添加的footer
脚本:
<script src="https://cdn.ckeditor.com/4.11.2/full/ckeditor.js"></script>
<script>
var editor = CKEDITOR.replace('editor1', {
height: 400,
uiColor: '#E4E4E4',
toolbarCanCollapse: true,
language: 'ar',
extraAllowedContent: 'span;ul;li;table;td;style;*[id];*(*);*{*}',
allowedContent: true,
});
</script>
任何帮助!?