js获取焦点

 

<input type = "text" id="football" />dom

对上面获取焦点。对象

1.获取dom对象get

var domFocus = document.getElementById("football");input

2.dom对象获取焦点document

domFocus.focus();focus

相关文章
相关标签/搜索