JSFiddle - React, Tailwind, and code Playground
by andrenmaia
HTML
<link rel="stylesheet" href="http://netdna.bootstrapcdn.com/bootstrap/3.0.0/css/bootstrap.min.css">
<script src="http://netdna.bootstrapcdn.com/bootstrap/3.0.0/js/bootstrap.min.js"></script>
<link rel="stylesheet" href="http://netdna.bootstrapcdn.com/font-awesome/3.2.1/css/font-awesome.min.css">
<button> popover me </button>
<button> popover me2 </button>
CSS
body{
padding:10px;
}
JavaScript
function cc(){
alert('aaa');
}
$(function () {
$('button').popover({
html: true,
title: 'title',
content: 'content',
container: 'body',
trigger: 'hover',
placement: 'auto bottom'
});
$('button').click(function(e){
$(this).popover('destroy');
$(this).popover({
html: true,
title: 'title2 <button onclick="javascript:cc();" >fechar</button>',
content: 'content2',
container: 'body',
trigger: 'click',
placement: 'auto bottom'
});
$(this).popover('show');
});
});