input 文本框自动显示光标

使用$("#votetitle").focus();没起作用

使用document.getElementById("votetitlechild").focus();也没有起作用

最后在网上查了一个方法,起作用了

setTimeout("document.getElementById(\"votetitle\").focus()",50);

posted @ 2018-07-25 17:16  edgar-li  阅读(2962)  评论(0)    收藏  举报