2008-10-02 76 views

回答

1

我从YUI library的文档中得到了这个。具体而言,在标题为样品Editor - Basic Buttons

var myEditor = new YAHOO.widget.Editor('editor', {focusAtStart:true});
myEditor.render();

这里的关键是 “focusAtStart” 属性作为可选属性的一部分的对象

0

我还没有使用的YAHOO丰富文本编辑器,但不会工作,如果你使用window.onload事件?)

0

像roenving,我从来没有使用YAHOO富文本编辑器,但它应该与window.onload事件。

假设您为您的YAHOO富文本编辑器指定了id="yahoo_text_editor"
然后,做

<body onload="document.getElementById('yahoo_text_editor').focus()"> 

希望这有助于。