我已经试过 $('#场)。重点()
,并在互联网上找到任何其他方法。毫无效果。我有一个简单的HTML能重现问题。
I've tried $('#field').focus()
, and any other method found on the internet. Nothing worked. I have a simple html that reproduces the problem.
<!DOCTYPE html>
<html>
<head>
<script type="text/javascript" src="https://ajax.googleapis.com/ajax/libs/jquery/1/jquery.min.js"></script>
<script type="text/javascript">
$(document).ready(function() {
$('#field').focus();
});
</script>
</head>
<body>
<input type="text" id="field" name="field"/>
</body>
</html>
请帮忙!
其实,JavaScript函数焦点被停用的Android浏览器一般。因此,jQuery的重点功能被禁用,因为它使用上面。
Actually, the general javascript function "focus" is deactivated in the android browser. Hence, the jQuery focus function is deactivated since it's using the above.