blazeworx / flagstrap

A lightwieght jQuery plugin for creating Bootstrap 3 compatible country select boxes with flags
http://blazeworx.github.io/flagstrap
MIT License
88 stars 62 forks source link

onSelect event doesn't work #42

Open shubham-ralli opened 2 years ago

shubham-ralli commented 2 years ago

jQuery('#flagstrap3').flagStrap({ countries: { "US": "USD", "EU": "EUR", "GB": "GBP", "AU": "AUD", }, inputName: 'country', labelMargin: "20px", scrollable: false, scrollableHeight: "350px", onSelect: function(value, element) { alert(value); }

Servibe commented 11 months ago

Try adding a specific click event on the items.

$('#idioma .dropdown-menu li a').click(function (e) {
    e.preventDefault();

    console.log($(this).data('bsVal'));
  });