<div ng-app= "module" ng-controller= "Ctrl" Style= "Text-align:center" > <!--original value--> {price}} <br> <!--Use the currency filter--> {price|currency}} <br> <!--Use the currency filter with a fixed prefix--> {{price|currency: ' ¥ '} <br> <!--Use the currency filter with a fixed prefix and take only 1 decimal--> {{price|currency: ' ¥ ': 1}} <br> <!--use number over Filter and take only 2 decimal--> {{price|number:2}}<br> <!--original value--> {{name}} <br> <!--use lowercase to lowercase-- > {{name|lowercase}} <br> <!--use uppercase to capitalize--> {{name|uppercase}} <br> <!--original Value-
> {{Data}} <br> <!--limit Display 2 characters--> {data|limitto:2}} <br> <!--limit Displays the first 4 words starting from 0 subscript--> {{data|limitto:4:0}} <br> <!--restricts the display of the first 4 characters from the 2 subscript--> {Data|limitto:4:2}} <br> <!--the original value timestamp- -> {Time}} <br> <!--date--> {time|date: ' yyyy mm monthly dd Day HH when mm minutes ss seconds '} <br> </div> &L t;script> var m = Angular.module (' module ', []);
M.controller (' Ctrl ', [' $scope ', function ($scope) {//* value, Currency filter/$scope. price=1234.567;
/* Case Filter/$scope. name= ' BaiDu ';
* * Word limit filter/$scope. Data= ' Welcome to browse cool blog on the way;
/* Date Filter/$scope. Time=new date (). GetTime ();
}]); </script>
Run Result: