press and hold button javascript

前端 未结 3 913
余生分开走
余生分开走 2021-01-25 19:31

I\'m having a problem with my button in my HTML5 application. When I press the button a Video player runs and plays the video that is stored locally. My issue now is that when I

3条回答
  •  温柔的废话
    2021-01-25 20:13

    Use onmouseup event.

    var button = //your button
    
    button.onmouseup = function() {
    //your logic
    
    }
    

提交回复
热议问题