I've 2 functions that works perfectly. I want to let them work together. One of them is a slider. see the code below.
<script>
$(function(){
$(".cloudslider-handle").slider({
range:"min",
value:1,
min:1,
max:10,
slide:function(event,ui){
$(".a,.b,.c,.d").width(ui.value * 10+"%");
}
});
$(".ui-slider-handle").text("<>");
$(".a,.b,.c,.d").width(10+"%");
});
</script>
And the other one is a speedometer. see the code below
<script>
document.addEventListener("DOMContentLoaded", function(event) {
var gg1 = new JustGage({
id: "gg1",
formatNumber: true,
counter: true
});
});
</script>
How can i write the code so that when i slide the slider to a value say 2 for example that the value will be passed to the speedometer?