0

I have created a button with an Popover with a form-control inside. The popover works, but the content inside data-content is shown as a normal string. How can I change this?

<button type="button" class="btn btn-primary" 
        data-toggle="popover" data-placement="bottom"  
        title="Sort..." data-content='<input id="aaa" type="text" class="form-control" placeholder="search"/>'>

            <span class="glyphicon glyphicon-sort"></span> sort
</button>

See this example on bootply.

d4rty
  • 3,970
  • 5
  • 34
  • 73
  • See the following answer. [Stack Overflow Similar Question](http://stackoverflow.com/questions/12128425/contain-form-within-a-bootstrap-popover) – Mike Wood May 03 '16 at 10:36

1 Answers1

0

You need to add data-html='true' to your popover button.

Here is an updated JSFiddle

Mike Wood
  • 154
  • 8