Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Selectpicker title change text

I am using https://silviomoreto.github.io/bootstrap-select/. I am using multi-select dropdown. On selecting some items, it shows its default title "x items selected". I want to change its text to "x some_other_word selected.". Anyone tell me, if this plugin provides any option to change the title text.

like image 903
sanjeev1779 Avatar asked Sep 20 '25 19:09

sanjeev1779


1 Answers

you can use "data-count-selected-text"

<select class="selectpicker" multiple data-selected-text-format="count>3"
    data-count-selected-text= "{0} some_other_word selected">
     <option>Mustard</option>
      <option>Ketchup</option>
      <option>Relish</option>
      <option>Onions</option>
</select>
like image 148
Marcos Alvarado Avatar answered Sep 22 '25 09:09

Marcos Alvarado