It's not like putting a string with a scoop in the html to make those things work.
-
I didn't come up with a clear and clear idea of the problem, I guess I was in the google and couldn't find a more similar question, unfortunately. There's an annex on the hangar, in the scoop, I'm getting a response from the server-- the already deformed template of xml, which is, respectively, recovered (and stored) as a row. I've been in the middle of it, I'm just doing it in the chtmple, but he's putting it in line and theater. There was another option from the angular-sanitize, which should be redesigned to the text with the process of the tags, but also without result. ♪
app.controller('Controller', function($scope) { $scope.text = "<!doctype html><html lang='en'><head><meta charset='UTF-8'><title>Document</title></head><body><h1>Hello world</h1></body></html>" })
Example https://plnkr.co/edit/pdd0KKnZsFlfRWVBKJqM?p=preview
-
This may be used. https://docs.angularjs.org/api/ng/directive/ngBindHtml and https://docs.angularjs.org/api/ng/service/$sce
var app = angular.module('App', []);
app.controller('Controller', function($scope, $sce) {
$scope.text = $sce.trustAsHtml("<h1>Hello world</h1>");
});<script src="https://ajax.googleapis.com/ajax/libs/angularjs/1.5.5/angular.js"></script>
<span ng-app="App" ng-controller="Controller" data-ng-bind-html="text"></span>Libo https://docs.angularjs.org/api/ngSanitize
var app = angular.module('App', ['ngSanitize']);
app.controller('Controller', function($scope) {
$scope.text = "<h1>Hello world</h1>";
});<script src="https://ajax.googleapis.com/ajax/libs/angularjs/1.5.5/angular.js"></script>
<script src="//ajax.googleapis.com/ajax/libs/angularjs/1.5.5/angular-sanitize.js"></script>
<span ng-app="App" ng-controller="Controller" data-ng-bind-html="text"></span>