I tried to make bootstrap popover,for that I written the following code as per bootstrap guide.
I am using bootstrap 3.1.0.
<input id="shelfLifeField" type="text" placeholder="Use-By" class="form-control first" data-container="body" data-toggle="popover" data-placement="bottom" data-html="true" data-content="<div class='row'>this is just for text</div>"/>
it's working fine but the problem was popover content appending to body.For this I read bootstrap documentation finally I find, I can control through data-container attribute.
so I tried with the following way.
data-container="#anotherDivId"
Actually what I am trying,I want to append popover content to specific div("anotherDivId") instead of appending to body.
I failed with my idea so can anyone help me.
Thanks.
data-container="#anotherDivId" is right and should work.
Be careful though that if #anotherDivId is hidden (with display:none), then the popover won't work
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With