Pass html into view in $ionicPopUp and $ionicModal

The HTML tags is shown in content.
How to load HTML tags in ionic Popup Content?

It should show the content as HTML as below:
Expected content :

CLICK GOOGLE

- - - - - - - - - - - - - - - -

 <pre>
 CLICK <a href="http://www.GOOGLE.COM" target=_blank>GOOGLE</a>
 <br>- - - - - - - - - - - - - - - - <br>   
</pre>

CODE:

 message-read.php
  <div class="list">
       <div class="item item-divider">        
             <p>Dari : {{data.admin}}</p>
             <p>{{data.date}}</p>
      </div>

     <div class="item item-text-wrap">

   {{(data.descr)}}

    </div> 
</div>


  var myPopup = $ionicPopup.show({
     templateUrl: "/user/message-read.php",
     title: $scope.data.title,
     scope: $scope,
     buttons: [{
        text: '<b>Close</b>',
        type: 'button-positive',
      }]
  });

on ionicModal

image

Why are your templates .php files?

yes it is a php type of file. :slight_smile:
I have just found the solution. Angular need to trust it as an html so we can insert it into view.

on controller

$scope.data.descr = $sce.trustAsHtml($scope.data.descr);

on message-read.php

<div class="item item-text-wrap" ng-bind-html="data.descr"></div>