CKEditor 3.0 Height

前端 未结 10 1333
暗喜
暗喜 2020-12-29 08:36

Is there a way to set the height of CKEditor 3.0 to a percentage, such as 100%, such that it takes up the whole window?

I am currently using absolute values, but the

10条回答
  •  遥遥无期
    2020-12-29 09:14

    I managed to configure a 100% height via CSS:

    1. Configure the editor with config.height = '100%', even when the docs say this isn't supported.
    2. Put this in your CSS:
    span.cke_wrapper cke_ltr,table.cke_editor, td.cke_contents, span.cke_skin_kama, span.cke_wrapper, span.cke_browser_webkit{
        height: 100%!important;
    }
    

    I tested this with Chrome, Firefox and Safari and it worked fine. Since this is pure CSS, the height will get adjusted automatically when the window or the corresponding container is resized.

提交回复
热议问题