gpt4 book ai didi

javascript - 将插入符号设置为在焦点 CKEditor 之后结束

转载 作者:数据小太阳 更新时间:2023-10-29 05:27:16 24 4
gpt4 key购买 nike

<分区>

Possible Duplicate:
CKEditor - Set cursor position to end of text

我有一个 <div>有很多内容。单击此 div 后,将加载 CKEditor 以编辑此 div。

现在我想在用编辑器替换它之后将插入符号/光标设置到内容的末尾。

我的代码目前是这样的:

var editor = CKEDITOR.replace('content', {
// Settings

// Event listeners
on: {
instanceReady: function(evt) {
var editor = evt.editor;

// give focus (displays caret at the beginning of the content, not the end)
editor.focus();
}
}
});

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com