Bootstrap popover with function driven content

In another post, I wrote about a technique that allowed loading content into a popover using a function.

Its a great feature but I found one gotcha. If you set anything in the data-content attribute on the trigger element, the content will not be loaded with the function.

Maybe I should say that again for myself, If you want to use content: function() {...} your element must not include data-content

Don't use:
<a id="mypopover" href="#" 
   data-content="will not run function"> Label </a>
Use:
<a id="mypopover" href="#" > Label </a>
__END__

Comments

Popular posts from this blog

Changing Dancer::Plugin::Ajax's content type

BootstrapX clickover

2 ways to get SQLite to put dates into columns