我想在ckeditor里面显示我在数据库读出的内容,但是加载ckeditor编辑器失败了,chrome报错:Uncaught TypeError: Cannot call method 'equals' of undefined 。但是如果我不用显示内容的时候,直接加载编辑器是可以成功的,这是怎么回事了?
上代码
水平低,猜不到~~
上代码
水平低,猜不到~~
<span style="float:left;"><textarea id="content" name="content">{$vo.content}</textarea></span><span class="require-field">*</span> <script type="text/javascript"> //<![CDATA[ CKEDITOR.replace('content',{width:600}); //]]> </script><p style="text-align: center;"> <u><strong><em><span style="font-size:26px;">21212</span></em></strong></u></p><p> <u><strong><em><span style="font-size:26px;">213131312121</span>121212321</em></strong></u></p>
<div class="aritcle_card">
<a class="aritcle_card_img" href="/ai/1579">
<img src="https://img.php.cn/upload/ai_manual/000/000/000/175680266325758.png" alt="无涯·问知">
</a>
<div class="aritcle_card_info">
<a href="/ai/1579">无涯·问知</a>
<p>无涯·问知,是一款基于星环大模型底座,结合个人知识库、企业知识库、法律法规、财经等多种知识源的企业级垂直领域问答产品</p>
<div class="">
<img src="/static/images/card_xiazai.png" alt="无涯·问知">
<span>40</span>
</div>
</div>
<a href="/ai/1579" class="aritcle_card_btn">
<span>查看详情</span>
<img src="/static/images/cardxiayige-3.png" alt="无涯·问知">
</a>
</div>
<ol> <li> <span style="font-size:36px;">232123213<br /> </span></li></ol> 输入一些简单字符入库并读取是否正常,如果正常,可能是录入内容的问题,ckeditor编辑器好像已对内容的HTML标签做了处理,入库的时候就不需要再做处理了。
如果录入简单字符入库读取也出错,看看是不是ckeditor配置上的问题。
输入一些简单字符入库并读取是否正常,如果正常,可能是录入内容的问题,ckeditor编辑器好像已对内容的HTML标签做了处理,入库的时候就不需要再做处理了。
如果录入简单字符入库读取也出错,看看是不是ckeditor配置上的问题。
????里?出?的?容用
htmlspecialchars($,ENT_QUOTES,'UTF-8') //??HTML??,且中文不??
htmlspecialchars_decode($,ENT_QUOTES) //把HTML??反向??
??一下就行了
具体看下editor配置是否有问题,按照你这样显示数据,是没有问题。
每个人都需要一台速度更快、更稳定的 PC。随着时间的推移,垃圾文件、旧注册表数据和不必要的后台进程会占用资源并降低性能。幸运的是,许多工具可以让 Windows 保持平稳运行。
Copyright 2014-2025 https://www.php.cn/ All Rights Reserved | php.cn | 湘ICP备2023035733号