Friday, 20 July 2018

AngularJS Expressions

AngularJS expressions are written inside double braces: {{ expression }}.
Example 1:
<!DOCTYPE html>
<html>
<script src="https://ajax.googleapis.com/ajax/libs/angularjs/1.6.9/angular.min.js"></script>
<body>
<div ng-app="">
 <p>Enter Age:</p>
<p>Age: <input type="text" ng-model="ag"></p>
<p>{{ag}}</p>
</div>
</body>
</html>
Example 2:
<!DOCTYPE html>
<html>
<script src="https://ajax.googleapis.com/ajax/libs/angularjs/1.6.9/angular.min.js"></script>
<body>

<div ng-app="">
 <p>Enter two number:</p>
<p>a value: <input type="number" ng-model="a"></p>
<p>b value: <input type="number" ng-model="b"></p>
<p>{{(a+b)}}</p>
</div>
</body>
</html>

1 comment:

  1. Python is an open-source, high level, interpreted programming language which offers great opportunities for object-oriented programming. Choosing a python training program from Red Prism Group, which is best training institute for python in noida.

    ReplyDelete

Global Infrastructure and its components in AWS

You may operate your workloads wherever and however you choose with the AWS Global Infrastructure, and you'll use the same network, cont...