spechars.html 添加这么一行
<link href="//cdn.bootcss.com/font-awesome/4.6.3/css/font-awesome.min.css" rel="stylesheet">
spechars.js 添加一行
var charsContent = [
{ name:"fonta", title:lang.fonta, content:toArray('<i class="fa fa-ambulance"></i>,<i class="fa fa-automobile"></i>,<i class="fa fa-bicycle"></i>,<i class="fa fa-bus"></i>,<i class="fa fa-cab"></i>,<i class="fa fa-car"></i>,<i class="fa fa-fighter-jet"></i>,<i class="fa fa-motorcycle"></i>,<i class="fa fa-plane"></i>,<i class="fa fa-rocket"></i>,<i class="fa fa-ship"></i>,<i class="fa fa-space-shuttle"></i>,<i class="fa fa-subway"></i>,<i class="fa fa-taxi"></i>,<i class="fa fa-train"></i>,<i class="fa fa-truck"></i>,<i class="fa fa-wheelchair"></i>')}
];
en.js 添加fonta一行 zh-cn.js也是
spechars: {
'static': {},
tsfh: "Special",
lmsz: "Roman",
szfh: "Numeral",
rwfh: "Japanese",
xlzm: "The Greek",
ewzm: "Russian",
pyzm: "Phonetic",
zyzf: "Others",
fonta:'font awesome'
},
ueditor.all.min.js
搜索 root.getNodesByTagName('b i') 把 node.tagName = 'em'; 替换node.tagName = 'i';
me.addInputRule(function (root) {
utils.each(root.getNodesByTagName('b i'), function (node) {
switch (node.tagName) {
case 'b':
node.tagName = 'strong';
break;
case 'i':
node.tagName = 'i';
}
});
});
搜到preview
加入css样式 就可以了
,iframeCssUrl:'//cdn.bootcss.com/font-awesome/4.6.3/css/font-awesome.min.css' //给编辑器内部引入一个css文件
如果出现编缉器下拉框显示不全 在ueditor.css里加入这么一行
.edui-popup-content.edui-default{ height: auto !important; }
效果完成后