Home > php教程 > php手册 > body text

解决dedecms5.7编辑器回车后是BR而不是P - tutushow

WBOY
Release: 2016-05-20 10:19:16
Original
1418 people have browsed it

织梦CMS有很多功能是比较受用的,但是也有很多小问题很让人头疼,每次升级怎么感觉都是麻烦事更多呢?dedecms5.7编辑器相信让很多人郁闷不已,就拿回车后是
而不是

这个来说,就很费大家心思了,因为以国人的浏览习惯来讲的话,一般我们都是段落之间空一段,通常代码就是

,但是新版5.7却返回的是
,这不是我们想要的,今天为大家解决这个问题。

找到:安装目录\include\ckeditor\config.js

config.autoParagraph = <span style="color: #0000ff;">false</span><span style="color: #000000;">;
config</span>.enterMode = CKEDITOR.<span style="color: #000000;">ENTER_BR;
config</span>.shiftEnterMode = CKEDITOR.ENTER_P;
Copy after login

把上面第二行、第三行换成

config.autoParagraph = <span style="color: #0000ff;">false</span><span style="color: #000000;">;
config</span>.enterMode = CKEDITOR.<span style="color: #000000;">ENTER_P;
config</span>.shiftEnterMode = CKEDITOR.ENTER_BP;
Copy after login

或者把下面代码注释掉就可以了

<span style="color: #008000;">//</span><span style="color: #008000;">config.autoParagraph = false;</span>
​<span style="color: #008000;">//</span><span style="color: #008000;">config.enterMode = CKEDITOR.ENTER_P;</span>
​<span style="color: #008000;">//</span><span style="color: #008000;">config.shiftEnterMode = CKEDITOR.ENTER_BP;​​</span>
Copy after login

 

source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Recommendations
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template