2

$('#header_user_list').html(''); を遅らせるにはどうすればよいですか この行は秒単位で実行されますか?

アプリケーション.js:

$(function() {
  $("#user_header_search_form input").focusout(function() {
    $('#header_user_list').html('');
  });
});
4

2 に答える 2

2

あなたはJavaScriptで行うことができます:

setTimeout(function(){$('#header_user_list').html('')}, 1000);

またはjQueryを使用:

$(function() {
  $("#user_header_search_form input").focusout(function() {
    $('#header_user_list').html('');
  }).delay(1000);
});
于 2013-07-10T23:47:51.647 に答える