Firstly, I think you need to use 
ng-bind-html<http://docs.angularjs.org/api/ng.directive:ngBindHtml> instead 
of ng-model, and the $sce is used when you trust
the source.
Secondly, why you put the html in a textarea? I wonder it could display 
nothing but only the html codes.

You can print your model to html page to see if the model really changes.
I mean something like <div>{{inputHtml}}</div>

The tex
On Wednesday, December 25, 2013 10:19:45 AM UTC+8, Giovanni Gaglione wrote:
>
> I have a textarea like this:
>>
>> <textarea class="col-md-12" ng-model="inputHtml"></textarea>
>>
>
> If the controller change the content of the textarea, using 
>
>> inputHtml=$sce.trustAsHtml(str)
>
>
> the content of textarea is never updated.
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"AngularJS" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/angular.
For more options, visit https://groups.google.com/groups/opt_out.

Reply via email to