diff --git a/docs/_includes/options/selections/clearing-selections.html b/docs/_includes/options/selections/clearing-selections.html index 9b99ef98..41ca96a8 100644 --- a/docs/_includes/options/selections/clearing-selections.html +++ b/docs/_includes/options/selections/clearing-selections.html @@ -29,6 +29,16 @@ $('select').select2({

Can users remove all of their selections in a multiple select at once?

- -

Yes, see: https://select2.github.io/examples.html#programmatic

+ +

+ Yes, by setting the value of the control to null: +

+ +{% highlight js linenos %} +$('select').val(null).trigger('change'); +{% endhighlight %} + +

+ See https://select2.github.io/examples.html#programmatic for a working example. +