JQuery Range Input Listener

后端 未结 5 844
-上瘾入骨i
-上瘾入骨i 2021-02-05 03:45

Hey having a little trouble jquery and the hmtl5 range. I\'m try to get the values as they changed but the event listener is not capturing it. Currently my code is:

HTML

5条回答
  •  悲&欢浪女
    2021-02-05 04:32

    $('input[type=range]').on('input', function () {
        $(this).trigger('change');
    });
    

    This fires the change event on every input event.

提交回复
热议问题