我使用按钮和 div 但在所有情况下 bootbox.js 将我的页面滚动到顶部。
$("#sampleButton").click(function(){
bootbox.alert("hey");
});
我使用按钮和 div 但在所有情况下 bootbox.js 将我的页面滚动到顶部。
$("#sampleButton").click(function(){
bootbox.alert("hey");
});
我通过使用jquery-impromptu解决了这个问题
尝试使用
$("#sampleButton").click(function(e){
e.preventDefault();
bootbox.alert("hey");
});