Eyecon的Bootstrap範圍滑塊在彼此頂部繪製多個滑塊。在行動中看到錯誤的位置:http://jsfiddle.net/GqMHM/Bootstrap範圍滑塊css bug
我已經採取了從作者的網站源代碼,以及例如在這個網站:http://www.qualitylink.com.br/slider/slider.html
對我的生活中,我想不通爲什麼我看到這個所有我的測試環境中的CSS錯誤。
<!-- Notice this exact example works [email protected] http://www.qualitylink.com.br/slider/slider.html -->
<html>
<head>
<meta charset="utf-8">
<title>Slider</title>
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<link rel="stylesheet" href="http://www.qualitylink.com.br/slider/css/bootstrap.min.css">
<link rel="stylesheet" href="http://www.qualitylink.com.br/slider/css/bootstrap.slider.css">
<script type="text/javascript" src="http://www.qualitylink.com.br/slider/js/jquery.js"></script>
<script type="text/javascript">
$(document).ready(function() {
$('.slider').slider({
min: 5,
max: 500,
step: 5,
value: [5,200]
});
$('.tooool').tooltip();
});
</script>
</head>
<body>
<!-- Button to trigger modal -->
<a href="#myModal" role="button" class="btn" data-toggle="modal">Launch demo modal</a>
<!-- Modal -->
<div id="myModal" class="modal hide fade" tabindex="-1" role="dialog" aria-labelledby="myModalLabel" aria-hidden="true" style="display: none;">
<div class="modal-header">
<button type="button" class="close" data-dismiss="modal" aria-hidden="true">×</button>
<h3 id="myModalLabel">Modal header</h3>
</div>
<div class="modal-body">
<br><br>
<div class="slider slider-horizontal" style="width: 220px;">
<div class="slider-track"><div class="slider-selection" style="left: 0%; width: 27.272727272727273%;"></div>
<div class="slider-handle round" style="left: 0%;"></div>
<div class="slider-handle round" style="left: 27.272727272727273%;"></div>
</div>
<div class="tooltip top" style="top: -24px; left: 5.5px;">
<div class="tooltip-arrow"></div><div class="tooltip-inner">5 : 140</div>
</div>
<input type="text" class="slider" style="">
</div>
<br><br>
</div>
<div class="modal-footer">
<button class="btn" data-dismiss="modal" aria-hidden="true">Close</button>
<button class="btn btn-primary">Save changes</button>
</div>
</div>
<script src="http://www.qualitylink.com.br/slider/js/bootstrap.min.js"></script>
<script type="text/javascript" src="http://www.qualitylink.com.br/slider/js/bootstrap.slider.js"></script>
</body>
</html>
嗨@user歡迎來到SO。我看不到你描述的錯誤,看起來好像一切正常。有兩個滑塊,因爲它顯然是一個值的範圍。源代碼只顯示兩個滑塊,而不是「在彼此之上的多個滑塊」。 – Ben