CKEDITOR, AutoFocus on the text editor onLoad

后端 未结 3 1227
故里飘歌
故里飘歌 2021-02-08 04:07

Anyone know how to autofocus on the CKEDITOR text area on page load?

Currently the user has to click in the text area before they can start typing. Like Google, I\'d lik

相关标签:
3条回答
  • In your config simply do this:

        config.startupFocus = true;
    
    0 讨论(0)
  • 2021-02-08 04:27

    Perhaps the startupFocus config option?

    CKEDITOR.replace( 'meeting_notes',
        {
            startupFocus : true,
            toolbar :
    ...
    
    0 讨论(0)
  • 2021-02-08 04:37

    I've not tried it myself, but check out the CKEDITOR.config.startupFocus.

    Definition: Sets whether the editor should have the focus when the page loads.

    0 讨论(0)
提交回复
热议问题