lizardtechblog / Leaflet.OpacityControls

Simple Leaflet controls to adjust the opacity of a map.
BSD 3-Clause "New" or "Revised" License
30 stars 18 forks source link

Control.Opacity.js?ver=4.4.2:62 Uncaught TypeError: jQuery(...).slider is not a function #7

Closed celine-y closed 8 years ago

celine-y commented 8 years ago

I've tried changing the version of jQuery to a newer one to match the one used on our site. As well as commenting out the other version of jQuery, however it still gives me the error: Control.Opacity.js?ver=4.4.2:62 Uncaught TypeError: jQuery(...).slider is not a function and it's saying the error is at: $(opacity_slider_div).slider({ orientation: "vertical", range: "min", min: 0, max: 100, value: 60, step: 10, start: function ( event, ui) { //When moving the slider, disable panning. map.dragging.disable(); map.once('mousedown', function (e) { map.dragging.enable(); }); }, slide: function ( event, ui ) { var slider_value = ui.value / 100; opacity_layer.setOpacity(slider_value); } }); I've also tried changing $ to jQuery.

Thanks