【发布时间】:2016-10-03 08:14:32
【问题描述】:
<div>
<CKEditor:CKEditorControl ID="CKEditor1" BasePath="~/ckeditor/" runat="server" Width="1108px" Height="383px"></CKEditor:CKEditorControl>
</div>
<script type = "text/javascript">
$(document).ready(function () {
CKEDITOR.on('instanceCreated', function (e) {
e.editor.on('contentDom', function () {
e.editor.document.on('keydown', function (event) {
if (event.data.$.keyCode == 97) {
alert('Key Pressed');
}
});
});
});
});
</script>
上面的代码我尝试过但无法正常工作。如果有人知道,请分享。 在 CKEditor 中输入时如何显示警报消息?在 ASP.NET Web 应用程序中使用 javascript/c#。
【问题讨论】:
-
函数被调用了吗?
标签: javascript c# css ckeditor