javascript - Error displaying info on Tooltip with AngularStrap -


i trying display info in tooltip , getting title enter image description here

and here html call it

                    <button class="btn btn-primary"                             type="button"                             ng-click="moreinfoslip(slip)"                             data-trigger="click"                             data-type="success"                             data-title="{{tooltip.title}}"                             bs-tooltip>                             click me                     </button> 

and here js

  $scope.moreinfoslip = function(slip) {     console.log(slip);     $scope.tooltip = {         title: '<strong>pick info</strong>',         content: '<div class="selection-info"><p><strong>game</strong> ' + slip.gamelineobj.name + '</p>' +         '<p><strong>league</strong> ' + slip.leagueobj.name + '</p>' +         '<p><strong>date</strong> ' + moment(slip.gamelineobj.date).format('mmmm yyyy, h:mm:ss a') + '</p>' +         '<p><strong>line</strong> ' + _.result(_.find(slip.lines, {isselected: '1'}), 'pick') + '</p></div>'     };   } 

what doing wrong ?

you need set data-html="true" attribute of tooltip.

<button class="btn btn-primary"                             type="button"                             ng-click="moreinfoslip(slip)"                             data-trigger="click"                             data-type="success"                             data-html="true"                             data-title="{{tooltip.title}}"                             bs-tooltip>                             click me                     </button> 

Comments

Popular posts from this blog

php - failed to open stream: HTTP request failed! HTTP/1.0 400 Bad Request -

java - How to filter a backspace keyboard input -

java - Show Soft Keyboard when EditText Appears -