4

I am using ng-bind-html in my controller like

$scope.message='  You  currently have no ORDERS <a href= "javascript:void(0)" ng-click="Back()">Back13</a>';

and in html page

<strong ng-bind-html="message">Warning!</strong>

But the Back() is not working even i tried the $compile as similar question . Can any one solve this problem?

Community
  • 1
  • 1
Shekkar
  • 244
  • 3
  • 10
  • 21

1 Answers1

-1

Try this

$scope.message='  You  currently have no ORDERS <a **href="javascript:;"** ng-click="Back()">Back13</a>';

Change href="javascript:void(0)" to href="javascript:;"

and also see this below discussions

ng-click do not work when a template bound using ng-bind-html-unsafe

AngularJS: ng-bind-html doesn't work with button tag

Community
  • 1
  • 1
  • Thank you @user256103 for your response,but your suggestions are not working for me ,just now i have updated the code in [plunker](http://plnkr.co/edit/bpvGd5VhRj5IfvVc94ZW?p=preview) ,if possible change the plnkr to solve the problem. – Shekkar Sep 18 '14 at 06:54