如何从 javascript 更改 CKEditor 的大小
我正在使用 CKEditor 3.2,试图从 javascript 更改 ckeditor 的宽度和高度,我使用了多种方法,但均不成功:
// doesnt work 1:
CKEDITOR.instances.myinstance.width = 500;
// doesnt work 2:
CKEDITOR.instances.myinstance.width = 500;
CKEDITOR.instances.myinstance.updateElement();
// doesnt work 3:
CKEDITOR.instances.myinstance.config.width = 500;
// doesnt work 4:
CKEDITOR.instances.myinstance.config.width = 500;
CKEDITOR.instances.myinstance.updateElement();
有人知道如何做到这一点吗?
I'm using CKEditor 3.2, trying to change the width and height of the ckeditor from javascript, i have used several methods, all unsuccesful:
// doesnt work 1:
CKEDITOR.instances.myinstance.width = 500;
// doesnt work 2:
CKEDITOR.instances.myinstance.width = 500;
CKEDITOR.instances.myinstance.updateElement();
// doesnt work 3:
CKEDITOR.instances.myinstance.config.width = 500;
// doesnt work 4:
CKEDITOR.instances.myinstance.config.width = 500;
CKEDITOR.instances.myinstance.updateElement();
Anyone has any idea how to do this?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
使用 CKEDITOR.instances.myinstance.resize(500, 400)
Use
CKEDITOR.instances.myinstance.resize(500, 400)