我正在使用 Twitter Bootstrap 弹出框来进行一种用于删除特定表行的警报确认,并且似乎无法让弹出框内的按钮影响任何内容。我已经在弹出框外复制了确切的“取消”按钮,它工作正常。http://jsfiddle.net/UK7BE/1/
HTML
<span class="glyphicon glyphicon-trash icon-set delLtBlue delPop" title='Delete'
data-content="
<div style='font-size: 14px; color: #000000; font-weight:bold'>
<span class='icon-warning-2'></span> Are you sure you want to delete the selected row?<br/><br/>
</div>
<input type='button' value='Cancel' class='greenBtn cancelPop' /> <input type='button' value='Delete' class='greenBtn' id='delete' />
" title="Delete"></span>
jQuery
$('.delPop').popover({
placement:'bottom',
html : true,
});
$("input[type=button].cancelPop").on('click',function(){
$(".delPop").popover('hide');
});
有任何想法吗?提前致谢。