Javascript 如何在网页加载时自动按tab键
网页加载时,每5秒自动按tab键可以做什么Javascript 如何在网页加载时自动按tab键,javascript,Javascript,网页加载时,每5秒自动按tab键可以做什么 $('.tg').bind('keypress', function(event) { if(event.which === 38) { var nextItem = $(this).next('.tg'); if( nextItem.size() === 0 ) { nextItem = $('.tg').eq(0); } nextItem.focus(); } }); 类似
$('.tg').bind('keypress', function(event) {
if(event.which === 38) {
var nextItem = $(this).next('.tg');
if( nextItem.size() === 0 ) {
nextItem = $('.tg').eq(0);
}
nextItem.focus();
}
});
类似