Home > Enterprise >  Remove title from select2
Remove title from select2

Time:01-19

I am using enter image description here

Output is like below.

enter image description here

CodePudding user response:

Here's a minimal solution for your use case:

$("#select2-data-16-lf0b").removeAttr("title")

CodePudding user response:

You can select the elements by their class and remove its attribute this way.

$('.select2-selection__choice').removeAttr('title')

hope have helped you.

CodePudding user response:

A simple solution to select the selected options. This will work at any action either its selection or unselection.

$("yourselector").on("select2:select select2:unselect", function (e) {
    $(this).removeAttr("title");       
});

This may help you

  •  Tags:  
  • Related