我是这样写的,我的代码已经处理过,但只要在源代码与html代码中切换就不行
我希望自己的代码能在submit事件中处理kindeditor编辑过的代码。
var editor;
KindEditor.ready(function (K) {
editor = K.create("textarea[name='" +txtAreaID + "']", {
filterMode: false,
cssPath: '/Manage/js/kindeditor/plugins/code/prettify.css',
uploadJson: '/Manage/Server/UpMorePic.aspx?cmd=editor&wsid=' + wsID + '&token=' + token,
fileManagerJson: '/Manage/js/kindeditor/asp.net/file_manager_json.ashx?wsid=' + wsID + '&token=' + token,
allowFileManager: true,
items: keExtend.items
});
addEvent(document.forms[0], "submit", function () {//对百度地图代码进行处理
var v = document.getElementById(txtAreaID).value;
v=replaceBaiduMapString(v);
document.getElementById(txtAreaID).value = v;
});
});