I have added a NiceScroll
bar to a div:
$("#div-name").niceScroll();
How can I remove/destroy it?
I have tried the following, but it doesn't work:
$("#div-name").getNiceScroll().stop();
The following is also not a solution:
$("#div-name").getNiceScroll().resize();
$("#div-name").getNiceScroll().hide();
EDIT: I found the problem! When adding NiceScroll
to divs that are automatically generated by the JQuery Multiselect plugin, on iPad I have some visualization problems on other NiceScroll
divs. So it's probably an issue relating to the integration of the two plugins(NiceScroll
and JQuery
MultiSelect
).
But this works $("#ID").getNiceScroll().remove();
Try to execute in console on nicescroll demo page: $("#boxscroll2").getNiceScroll().remove()
and you'll see that first div This is a simple scrollable DIV will change from nicescroll scrollbars to native browser ones.