is there a better way to close select2 when you click away? I have it closing with
$(document).click(function(event) {
if(!$(event.target).hasClass("select2-selection__rendered") &&
!$(event.target).hasClass("select2-results__option")) {
$("#e1").select2('close');
}
});
but that seems weird.
here is the fiddle http://jsfiddle.net/jEADR/5557/