I am attempting to create a simple setup for a bootstrap-style input slider, but I am facing some difficulties getting it to function properly.
Desired Outcome:
https://i.sstatic.net/Btfo3.png
Actual Outcome:
https://i.sstatic.net/0VnNv.png
Resource / Demo / Guide:
My Code / Issue / Error:
<html>
<head>
<link rel="stylesheet"
href="https://cdnjs.cloudflare.com/ajax/libs/bootstrap-slider/9.9.0/css/bootstrap-slider.css">
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.min.css">
</head>
<body>
<input id="ex1" data-slider-id='ex1Slider' type="text" data-slider-min="-5" data-slider-max="20" data-slider-step="1"
data-slider-value="14"/>
<script type='text/javascript'>
$('#ex1').slider({
formatter: function (value) {
return 'Current value: ' + value;
}
});
</script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/bootstrap-slider/9.9.0/bootstrap-slider.js"></script>
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.2.1/jquery.min.js"></script>
<script src="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/js/bootstrap.min.js"></script>
</body>
</html>
Note:
I have sourced all the necessary components (CSS/JS): bootstrap, bootstrap-slider, and JQuery from online repositories.