JS:
$(function(){
$(\"#example\").popover({
placement: \'bottom\',
html: \'true\',
title : \'
I found the code below very useful (taken from https://www.emanueletessore.com/twitter-bootstrap-popover-add-close-button/):
$('[data-toggle="popover"]').popover({
title: function(){
return $(this).data('title')+'×';
}
}).on('shown.bs.popover', function(e){
var popover = $(this);
$(this).parent().find('div.popover .close').on('click', function(e){
popover.popover('hide');
});
});