代码如下: [removed] //将光标聚焦在文本最后 function cursorEnd(){ var e = event.srcElement; var r = e.createTextRange(); r.moveStart(‘character’,e.value.length); r.collapse(true); r.select(); } [removed] <input type=text name=”test” va