1
  <div class="pop" style="display: none">
         'Dynamic content here'
    </div>
    <a href="#" class="opinionmap" rel="popover"><i class="icon-eye-open"></i></a>

$('.opinionmap').mouseenter(function() {
  $(this).popover({title: 'Current Opinion', trigger: 'hover', html: 'true', content: $(this).siblings('.pop').html(), placement: 'top'});
});

But the popover is working only after the second mouseenter event. I have viewed many related questions but none helped. Seeking answers!!!

4

2 に答える 2

1

これだけ使う

$('.opinionmap').popover({
    title: 'Current Opinion', 
    trigger: 'hover', 
    html: 'true', 
    content: $('.opinionmap').siblings('.pop').html(),
    placement: 'top'
});
于 2013-09-05T11:30:03.887 に答える
0

わかりました..だから、誰もが将来同じ問題を抱えています...これが私がそれを解決した方法です。

  $('.opinionmap').mouseenter(function() {
    $(this).popover({title: 'Current Opinion', trigger: 'hover', html: 'true', content: $(this).siblings('.pop').html(), placement: 'top'}).popover('show');
    ;
  });
于 2013-09-05T12:06:05.327 に答える