ckeditor:如何连接菜单按钮?
我已将 ckeditor 嵌入到我的页面之一......但我不知道如何连接 ckeditor 中的某些按钮来执行特定操作。最重要的是,当单击“保存”按钮保存文档时,我如何告诉它?
I have ckeditor embedded into one of my pages....but I don't know how to wire up certain buttons in ckeditor to perform specific actions. Most importantly, how do I tell it when the save button is clicked to save the document?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
Dave--
CKEditor 中保存按钮的美妙之处在于,它被默认设置为提交其所在的表单。在我公司的情况下,我在 CKEditor 中狂奔,希望必须禁用保存按钮,因为较大的表单已经有一个保存按钮...但事实证明它开箱即用。安装系统、测试并点击保存...看看会发生什么。
您可以控制 Config.js 文件中按钮的输出。如果您不喜欢某个特定按钮,您也可以使用 javascript 定义操作或创建新按钮。 http://docs.cksource.com/ 有关于这方面的相当好的教程
Dave--
The beauty of the save button in CKEditor is that it is setup default to submit the form that it's in. In my company's case, I bolted in CKEditor expecting to have to disable the save button because the larger form already had a save button...but it turns out that it worked right out of the box. Get the system installed, tested, and hit save...see what happens.
You can control the output of buttons in the Config.js file. If a particular button is not to your liking, you can use javascript to define actions or create new buttons there as well. There are fairly good tutorials on this at http://docs.cksource.com/