分前台和后台
前台页面要引入以下两个文件
<link rel="stylesheet" type="text/css" href="kindeditor-4.1.10/plugins/code/prettify.css" /> <script type="text/javascript" src="kindeditor-4.1.10/plugins/code/prettify.js"></script>
并且要执行函数
prettyPrint();
后台页面
如图:
第一个红框处,是为了在编辑器中能够正常显示样式
第二个红框处,code,是为了在工具栏中加上按钮